summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qwinnativepangesturerecognizer_win_p.h
diff options
context:
space:
mode:
authorDenis Dzyubenko <denis.dzyubenko@nokia.com>2010-06-11 10:36:34 (GMT)
committerDenis Dzyubenko <denis.dzyubenko@nokia.com>2010-06-11 10:53:44 (GMT)
commit7f338180e88b71e793069e2fbe9a70f3c434e126 (patch)
tree7a47674b62a955a0e816ae8cb8a93803ddc9fd8f /src/gui/kernel/qwinnativepangesturerecognizer_win_p.h
parent90a671581d2eef96f7ab5b04c1db798da24d0f6b (diff)
downloadQt-7f338180e88b71e793069e2fbe9a70f3c434e126.zip
Qt-7f338180e88b71e793069e2fbe9a70f3c434e126.tar.gz
Qt-7f338180e88b71e793069e2fbe9a70f3c434e126.tar.bz2
Changed the way we detect touch screen on Windows.
Instead of using the IInkTablets interface (which sometimes freezes in the get_Count() call for 10 seconds), we just check if there is digitizer support. Task-number: QTBUG-6007 Reviewed-by: Prasanth
Diffstat (limited to 'src/gui/kernel/qwinnativepangesturerecognizer_win_p.h')
-rw-r--r--src/gui/kernel/qwinnativepangesturerecognizer_win_p.h32
1 files changed, 32 insertions, 0 deletions
diff --git a/src/gui/kernel/qwinnativepangesturerecognizer_win_p.h b/src/gui/kernel/qwinnativepangesturerecognizer_win_p.h
index 64addeb..eb99b74 100644
--- a/src/gui/kernel/qwinnativepangesturerecognizer_win_p.h
+++ b/src/gui/kernel/qwinnativepangesturerecognizer_win_p.h
@@ -54,6 +54,38 @@
//
#include <QGestureRecognizer>
+#include <objbase.h>
+
+class IInkRectangle;
+class TabletHardwareCapabilities;
+class TabletPropertyMetricUnit;
+DECLARE_INTERFACE_(IInkTablet, IDispatch)
+{
+ STDMETHOD(get_Name)(THIS_ BSTR *Name) PURE;
+ STDMETHOD(get_PlugAndPlayId)(THIS_ BSTR *Id) PURE;
+ STDMETHOD(get_MaximumInputRectangle)(THIS_ IInkRectangle **Rectangle) PURE;
+ STDMETHOD(get_HardwareCapabilities)(THIS_ TabletHardwareCapabilities *Capabilities) PURE;
+ STDMETHOD(IsPacketPropertySupported)(THIS_ BSTR packetPropertyName) PURE;
+ STDMETHOD(GetPropertyMetrics)(THIS_ BSTR propertyName, long *Minimum, long *Maximum, TabletPropertyMetricUnit *Units, float *Resolution) PURE;
+};
+enum TabletDeviceKind
+{
+ TDK_Mouse = 0,
+ TDK_Pen = 1,
+ TDK_Touch = 2
+};
+DECLARE_INTERFACE_(IInkTablet2, IDispatch)
+{
+ STDMETHOD(get_DeviceKind)(THIS_ TabletDeviceKind *Kind) PURE;
+};
+DECLARE_INTERFACE_(IInkTablets, IDispatch)
+{
+ STDMETHOD(get_Count)(THIS_ long *Count) PURE;
+ STDMETHOD(get__NewEnum)(THIS_ IUnknown **_NewEnum) PURE;
+ STDMETHOD(get_DefaultTablet)(THIS_ IInkTablet **DefaultTablet) PURE;
+ STDMETHOD(Item)(THIS_ long Index, IInkTablet **Tablet) PURE;
+ STDMETHOD(IsPacketPropertySupported)(THIS_ BSTR packetPropertyName, VARIANT_BOOL *Supported) PURE;
+};
#include <objbase.h>