diff options
author | Klaus Reimer | 2011-05-08 20:45:50 +0200 |
---|---|---|
committer | Klaus Reimer | 2011-05-08 20:45:50 +0200 |
commit | 894469a50858493b54d28fb64cc6afc4e0b14552 (patch) | |
tree | e1f1ae7551fefe90798a2496bfd90835d1d20bbe /backends | |
parent | 31d86f90450093123e6dabda2e9503c233541678 (diff) | |
download | scummvm-rg350-894469a50858493b54d28fb64cc6afc4e0b14552.tar.gz scummvm-rg350-894469a50858493b54d28fb64cc6afc4e0b14552.tar.bz2 scummvm-rg350-894469a50858493b54d28fb64cc6afc4e0b14552.zip |
WEBOS: Fixed ESCAPE and MENU key on WebOS 1
Diffstat (limited to 'backends')
-rw-r--r-- | backends/events/webossdl/webossdl-events.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/backends/events/webossdl/webossdl-events.cpp b/backends/events/webossdl/webossdl-events.cpp index 045d077af2..989fffbc0f 100644 --- a/backends/events/webossdl/webossdl-events.cpp +++ b/backends/events/webossdl/webossdl-events.cpp @@ -92,6 +92,8 @@ void WebOSSdlEventSource::SDLModToOSystemKeyFlags(SDLMod mod, event.kbd.flags |= Common::KBD_SHIFT; if (mod & KMOD_CTRL) event.kbd.flags |= Common::KBD_CTRL; + + // Holding down the gesture area emulates the ALT key if (gestureDown) event.kbd.flags |= Common::KBD_ALT; } @@ -112,6 +114,14 @@ bool WebOSSdlEventSource::handleKeyDown(SDL_Event &ev, Common::Event &event) { return true; } + // Ensure that ALT key (Gesture down) is ignored when back or forward + // gesture is detected. This is needed for WebOS 1 which releases the + // gesture tap AFTER the backward gesture event and not BEFORE (Like + // WebOS 2). + if (ev.key.keysym.sym == 27 || ev.key.keysym.sym == 229) { + gestureDown = false; + } + // Call original SDL key handler. return SdlEventSource::handleKeyDown(ev, event); } |