Use higher values as a fallback for unknown keycodes on android
This commit is contained in:
parent
ba6bbd4133
commit
54c9fb97fa
@ -717,7 +717,7 @@ s32 CIrrDeviceAndroid::handleKeyboard(AInputEvent* androidEvent)
|
|||||||
// scan code, because it's better than nothing
|
// scan code, because it's better than nothing
|
||||||
if (event.KeyInput.Key == 0)
|
if (event.KeyInput.Key == 0)
|
||||||
{
|
{
|
||||||
event.KeyInput.Key = (EKEY_CODE)scanCode;
|
event.KeyInput.Key = (EKEY_CODE)((int)IRR_KEY_CODES_COUNT + scanCode);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Handle an event when back button in pressed just like an escape key
|
// Handle an event when back button in pressed just like an escape key
|
||||||
@ -868,7 +868,7 @@ s32 CIrrDeviceAndroid::handleGamepad(AInputEvent* androidEvent)
|
|||||||
|
|
||||||
if (event.KeyInput.Key == 0)
|
if (event.KeyInput.Key == 0)
|
||||||
{
|
{
|
||||||
event.KeyInput.Key = (EKEY_CODE)scanCode;
|
event.KeyInput.Key = (EKEY_CODE)((int)IRR_KEY_CODES_COUNT + scanCode);
|
||||||
}
|
}
|
||||||
|
|
||||||
postEventFromUser(event);
|
postEventFromUser(event);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user