summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qapplication_s60.cpp
diff options
context:
space:
mode:
authorwasila <qt-info@nokia.com>2010-02-25 15:14:37 (GMT)
committeraxis <qt-info@nokia.com>2010-02-25 16:03:47 (GMT)
commit133f853e569494303fc432f6c6009dd44c504446 (patch)
treeb6adaab24b1b8aa859ae604b9c79461f991399e5 /src/gui/kernel/qapplication_s60.cpp
parent1b9f273c3d0e10cb14a35a9a058b379b8777b5d8 (diff)
downloadQt-133f853e569494303fc432f6c6009dd44c504446.zip
Qt-133f853e569494303fc432f6c6009dd44c504446.tar.gz
Qt-133f853e569494303fc432f6c6009dd44c504446.tar.bz2
Enabled Qt key events to work also when native key code is missing.
If it is missing we base the event on the scan code instead. RevBy: Alessandro Portale Signed-off-by: axis <qt-info@nokia.com>
Diffstat (limited to 'src/gui/kernel/qapplication_s60.cpp')
-rw-r--r--src/gui/kernel/qapplication_s60.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gui/kernel/qapplication_s60.cpp b/src/gui/kernel/qapplication_s60.cpp
index fdbbeb2..2eecd56 100644
--- a/src/gui/kernel/qapplication_s60.cpp
+++ b/src/gui/kernel/qapplication_s60.cpp
@@ -597,7 +597,9 @@ TKeyResponse QSymbianControl::OfferKeyEvent(const TKeyEvent& keyEvent, TEventCod
TUint s60Keysym = QApplicationPrivate::resolveS60ScanCode(keyEvent.iScanCode,
keyEvent.iCode);
int keyCode;
- if (s60Keysym >= 0x20 && s60Keysym < ENonCharacterKeyBase) {
+ if (s60Keysym == EKeyNull){ //some key events have 0 in iCode, for them iScanCode should be used
+ keyCode = qt_keymapper_private()->mapS60ScanCodesToQt(keyEvent.iScanCode);
+ } else if (s60Keysym >= 0x20 && s60Keysym < ENonCharacterKeyBase) {
// Normal characters keys.
keyCode = s60Keysym;
} else {