diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2010-03-04 20:50:46 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2010-03-04 20:50:46 (GMT) |
commit | ac192ca74b90e059f96d6c24c4bb8295778d1eaa (patch) | |
tree | 28dbc4aca33bb6e90805e6b4e0980c3ae7002c10 /src/gui/kernel/qapplication_win.cpp | |
parent | f5b52405ea347a5cde4562f0375f1bed0f0d4b5d (diff) | |
parent | 95786655e304a22bd922b40184d314eddb72b002 (diff) | |
download | Qt-ac192ca74b90e059f96d6c24c4bb8295778d1eaa.zip Qt-ac192ca74b90e059f96d6c24c4bb8295778d1eaa.tar.gz Qt-ac192ca74b90e059f96d6c24c4bb8295778d1eaa.tar.bz2 |
Merge branch '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into 4.6-integration
* '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-1:
tst_qhostinfo: Compile fix
Document some stuff in QHostInfo and QAbstractSocket
tst_qhostinfo: Mixed up descriptions for test case data
qhostinfo benchmark: Use local _data instead of _global
DNS Cache: Also check inside the DNS threads
qhostinfo benchmark: Benchmark the with-cache and without-cache
tst_qftp: Do not use 1.2.3.4 as IP
Dont use gestures if there is no touch screen.
showFullscreen() broken if UnifiedTitleAndToolBarOnMac is enabled
Fix atk warning on startup in Qt apps wit QGtkStyle
Do not use realpath() with uclibc
Diffstat (limited to 'src/gui/kernel/qapplication_win.cpp')
-rw-r--r-- | src/gui/kernel/qapplication_win.cpp | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/src/gui/kernel/qapplication_win.cpp b/src/gui/kernel/qapplication_win.cpp index da6869d..49cb0f2 100644 --- a/src/gui/kernel/qapplication_win.cpp +++ b/src/gui/kernel/qapplication_win.cpp @@ -115,6 +115,8 @@ extern void qt_wince_hide_taskbar(HWND hwnd); //defined in qguifunctions_wince.c # include <winable.h> #endif +#include "private/qwinnativepangesturerecognizer_win_p.h" + #ifndef WM_TOUCH # define WM_TOUCH 0x0240 @@ -4000,12 +4002,45 @@ void QSessionManager::cancel() #endif //QT_NO_SESSIONMANAGER +bool QApplicationPrivate::HasTouchSupport = false; PtrRegisterTouchWindow QApplicationPrivate::RegisterTouchWindow = 0; PtrGetTouchInputInfo QApplicationPrivate::GetTouchInputInfo = 0; PtrCloseTouchInputHandle QApplicationPrivate::CloseTouchInputHandle = 0; void QApplicationPrivate::initializeMultitouch_sys() { + static const IID QT_IID_IInkTablets = {0x112086D9, 0x7779, 0x4535, {0xA6, 0x99, 0x86, 0x2B, 0x43, 0xAC, 0x18, 0x63} }; + static const IID QT_IID_IInkTablet2 = {0x90c91ad2, 0xfa36, 0x49d6, {0x95, 0x16, 0xce, 0x8d, 0x57, 0x0f, 0x6f, 0x85} }; + static const CLSID QT_CLSID_InkTablets = {0x6E4FCB12, 0x510A, 0x4d40, {0x93, 0x04, 0x1D, 0xA1, 0x0A, 0xE9, 0x14, 0x7C} }; + + IInkTablets *iInkTablets = 0; + HRESULT hr = CoCreateInstance(QT_CLSID_InkTablets, NULL, CLSCTX_ALL, QT_IID_IInkTablets, (void**)&iInkTablets); + if (SUCCEEDED(hr)) { + long count = 0; + iInkTablets->get_Count(&count); + for (long i = 0; i < count; ++i) { + IInkTablet *iInkTablet = 0; + hr = iInkTablets->Item(i, &iInkTablet); + if (FAILED(hr)) + continue; + IInkTablet2 *iInkTablet2 = 0; + hr = iInkTablet->QueryInterface(QT_IID_IInkTablet2, (void**)&iInkTablet2); + iInkTablet->Release(); + if (FAILED(hr)) + continue; + TabletDeviceKind kind; + hr = iInkTablet2->get_DeviceKind(&kind); + iInkTablet2->Release(); + if (FAILED(hr)) + continue; + if (kind == TDK_Touch) { + QApplicationPrivate::HasTouchSupport = true; + break; + } + } + iInkTablets->Release(); + } + QLibrary library(QLatin1String("user32")); // MinGW (g++ 3.4.5) accepts only C casts. RegisterTouchWindow = (PtrRegisterTouchWindow)(library.resolve("RegisterTouchWindow")); |