sm8250-common: KeyHandler: Do nothing when action != ACTION_DOWN
This makes sure we only change the ringer mode / play haptics once. Change-Id: Ie5a6050338cee75cd8fe6da6edfae03141263033
This commit is contained in:
@@ -50,6 +50,10 @@ public class KeyHandler implements DeviceKeyHandler {
|
||||
}
|
||||
|
||||
public KeyEvent handleKeyEvent(KeyEvent event) {
|
||||
if (event.getAction() != KeyEvent.ACTION_DOWN) {
|
||||
return event;
|
||||
}
|
||||
|
||||
int scanCode = event.getScanCode();
|
||||
|
||||
switch (scanCode) {
|
||||
|
||||
Reference in New Issue
Block a user