1
0
Fork 0

new dev bug: fixed scrolling in the language selection popup on Sonim XP3800

This commit is contained in:
sspanak 2025-05-29 15:15:36 +03:00 committed by Dimo Karaivanov
parent c2c2e2b75e
commit 1a03c55e0d
2 changed files with 13 additions and 0 deletions

View file

@ -45,6 +45,15 @@ public class Key {
}
public static boolean isArrow(int keyCode) {
return
keyCode == KeyEvent.KEYCODE_DPAD_UP
|| keyCode == KeyEvent.KEYCODE_DPAD_DOWN
|| keyCode == KeyEvent.KEYCODE_DPAD_LEFT
|| keyCode == KeyEvent.KEYCODE_DPAD_RIGHT;
}
public static boolean isBackspace(SettingsStore settings, int keyCode) {
return isHardwareBackspace(keyCode) || keyCode == settings.getKeyBackspace();
}

View file

@ -50,6 +50,10 @@ public class ChangeLanguageDialog extends PopupDialog {
@Override
public boolean onKey(DialogInterface dialog, int keyCode, KeyEvent event) {
if (Key.isArrow(keyCode)) {
return false;
}
if (event.getAction() == KeyEvent.ACTION_DOWN) {
return true;
}