summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/windows/qtwindowsglobal.h
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@digia.com>2014-07-02 15:44:49 +0200
committerAllan Sandfeld Jensen <allan.jensen@digia.com>2014-08-02 03:00:38 +0200
commit985ebe32f2ed9c899b26c98ccad2d1a08fa2326c (patch)
treec970244a3e860812ecb6ff7a7f88b8e945611c9f /src/plugins/platforms/windows/qtwindowsglobal.h
parentc0c80f14afba322179ac505816cdc51267b3a6ce (diff)
Support multimedia keys on Windows
We currently do not receive events from most multimedia keys on Windows because they are sent using appcommand events instead of the normal key events. This patchs adds support for parsing appcommand events. Change-Id: I19f568b6fa0d3d136e3a22318df1499a1fab6edb Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
Diffstat (limited to 'src/plugins/platforms/windows/qtwindowsglobal.h')
-rw-r--r--src/plugins/platforms/windows/qtwindowsglobal.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/plugins/platforms/windows/qtwindowsglobal.h b/src/plugins/platforms/windows/qtwindowsglobal.h
index 3992f2d297..1b2502af10 100644
--- a/src/plugins/platforms/windows/qtwindowsglobal.h
+++ b/src/plugins/platforms/windows/qtwindowsglobal.h
@@ -103,6 +103,7 @@ enum WindowsEventType // Simplify event types
AccessibleObjectFromWindowRequest = ApplicationEventFlag + 3,
QueryEndSessionApplicationEvent = ApplicationEventFlag + 4,
EndSessionApplicationEvent = ApplicationEventFlag + 5,
+ AppCommandEvent = ApplicationEventFlag + 6,
InputMethodStartCompositionEvent = InputMethodEventFlag + 1,
InputMethodCompositionEvent = InputMethodEventFlag + 2,
InputMethodEndCompositionEvent = InputMethodEventFlag + 3,
@@ -242,6 +243,10 @@ inline QtWindows::WindowsEventType windowsEventType(UINT message, WPARAM wParamI
case WM_ENDSESSION:
return QtWindows::EndSessionApplicationEvent;
#endif
+#if defined(WM_APPCOMMAND)
+ case WM_APPCOMMAND:
+ return QtWindows::AppCommandEvent;
+#endif
default:
break;
}