aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGarrett Brown <themagnificentmrb@gmail.com>2024-02-14 12:18:01 -0800
committerGarrett Brown <themagnificentmrb@gmail.com>2024-02-14 16:45:55 -0800
commitec608f332845b1fd26f2b5c6d7a3f3113ba49268 (patch)
tree720f6484f8645951c9dc15eb318f96c5a9c3a0ae
parentbb12e0e16f460e6c98047d82324354c51faadfae (diff)
Revert "[Android][Keyboard] Improve keypress logging"
This reverts commit 5349c0184b6eddaff6db9847648c91e808bdc41e.
-rw-r--r--xbmc/platform/android/activity/AndroidKey.cpp50
1 files changed, 20 insertions, 30 deletions
diff --git a/xbmc/platform/android/activity/AndroidKey.cpp b/xbmc/platform/android/activity/AndroidKey.cpp
index 3467ed6420..13e23b80a4 100644
--- a/xbmc/platform/android/activity/AndroidKey.cpp
+++ b/xbmc/platform/android/activity/AndroidKey.cpp
@@ -13,8 +13,6 @@
#include "input/keyboard/XBMC_keysym.h"
#include "windowing/android/WinSystemAndroid.h"
-#include "platform/android/peripherals/AndroidJoystickTranslator.h"
-
#include <androidjni/KeyCharacterMap.h>
typedef struct {
@@ -263,46 +261,38 @@ bool CAndroidKey::onKeyboardEvent(AInputEvent *event)
switch (action)
{
case AKEY_EVENT_ACTION_DOWN:
- CXBMCApp::android_printf("CAndroidKey: key down (dev: %d; src: %d; code: %d (%s); repeat: "
- "%d; flags: 0x%0X; alt: %s; shift: %s; sym: %s)",
- deviceId, source, keycode,
- PERIPHERALS::CAndroidJoystickTranslator::TranslateKeyCode(keycode),
- repeat, flags, (state & AMETA_ALT_ON) ? "yes" : "no",
- (state & AMETA_SHIFT_ON) ? "yes" : "no",
- (state & AMETA_SYM_ON) ? "yes" : "no");
+ CXBMCApp::android_printf(
+ "CAndroidKey: key down (dev: %d; src: %d; code: %d; repeat: %d; flags: 0x%0X; alt: %s; "
+ "shift: %s; sym: %s)",
+ deviceId, source, keycode, repeat, flags, (state & AMETA_ALT_ON) ? "yes" : "no",
+ (state & AMETA_SHIFT_ON) ? "yes" : "no", (state & AMETA_SYM_ON) ? "yes" : "no");
XBMC_Key((uint8_t)keycode, sym, modifiers, unicode, false);
break;
case AKEY_EVENT_ACTION_UP:
- CXBMCApp::android_printf("CAndroidKey: key up (dev: %d; src: %d; code: %d (%s); repeat: %d; "
- "flags: 0x%0X; alt: %s; shift: %s; sym: %s)",
- deviceId, source, keycode,
- PERIPHERALS::CAndroidJoystickTranslator::TranslateKeyCode(keycode),
- repeat, flags, (state & AMETA_ALT_ON) ? "yes" : "no",
- (state & AMETA_SHIFT_ON) ? "yes" : "no",
- (state & AMETA_SYM_ON) ? "yes" : "no");
+ CXBMCApp::android_printf(
+ "CAndroidKey: key up (dev: %d; src: %d; code: %d; repeat: %d; flags: 0x%0X; alt: %s; "
+ "shift: %s; sym: %s)",
+ deviceId, source, keycode, repeat, flags, (state & AMETA_ALT_ON) ? "yes" : "no",
+ (state & AMETA_SHIFT_ON) ? "yes" : "no", (state & AMETA_SYM_ON) ? "yes" : "no");
XBMC_Key((uint8_t)keycode, sym, modifiers, unicode, true);
break;
case AKEY_EVENT_ACTION_MULTIPLE:
- CXBMCApp::android_printf("CAndroidKey: key multiple (dev: %d; src: %d; code: %d (%s); "
- "repeat: %d; flags: 0x%0X; alt: %s; shift: %s; sym: %s)",
- deviceId, source, keycode,
- PERIPHERALS::CAndroidJoystickTranslator::TranslateKeyCode(keycode),
- repeat, flags, (state & AMETA_ALT_ON) ? "yes" : "no",
- (state & AMETA_SHIFT_ON) ? "yes" : "no",
- (state & AMETA_SYM_ON) ? "yes" : "no");
+ CXBMCApp::android_printf(
+ "CAndroidKey: key multiple (dev: %d; src: %d; code: %d; repeat: %d; flags: 0x%0X; alt: "
+ "%s; shift: %s; sym: %s)",
+ deviceId, source, keycode, repeat, flags, (state & AMETA_ALT_ON) ? "yes" : "no",
+ (state & AMETA_SHIFT_ON) ? "yes" : "no", (state & AMETA_SYM_ON) ? "yes" : "no");
return false;
break;
default:
- CXBMCApp::android_printf("CAndroidKey: unknown key (dev: %d; src: %d; code: %d (%s); repeat: "
- "%d; flags: 0x%0X; alt: %s; shift: %s; sym: %s)",
- deviceId, source, keycode,
- PERIPHERALS::CAndroidJoystickTranslator::TranslateKeyCode(keycode),
- repeat, flags, (state & AMETA_ALT_ON) ? "yes" : "no",
- (state & AMETA_SHIFT_ON) ? "yes" : "no",
- (state & AMETA_SYM_ON) ? "yes" : "no");
+ CXBMCApp::android_printf(
+ "CAndroidKey: unknown key (dev: %d; src: %d; code: %d; repeat: %d; flags: 0x%0X; alt: "
+ "%s; shift: %s; sym: %s)",
+ deviceId, source, keycode, repeat, flags, (state & AMETA_ALT_ON) ? "yes" : "no",
+ (state & AMETA_SHIFT_ON) ? "yes" : "no", (state & AMETA_SYM_ON) ? "yes" : "no");
return false;
break;
}