diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2010-04-19 03:58:41 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2010-04-19 03:58:41 (GMT) |
commit | ec5120f85225a0bf732908e0890ff9d483a01870 (patch) | |
tree | 6549c2f267c32021df4f8d4b5e0b70f690cd6020 /src/gui/kernel/qcursor_mac.mm | |
parent | a584ce0be29e9cb5cb0b627c71e4147011013418 (diff) | |
parent | cc52a813b396f8c4726d4c889bc391c015d36d11 (diff) | |
download | Qt-ec5120f85225a0bf732908e0890ff9d483a01870.zip Qt-ec5120f85225a0bf732908e0890ff9d483a01870.tar.gz Qt-ec5120f85225a0bf732908e0890ff9d483a01870.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1: (71 commits)
Autotest: increase wait time to 3s on Windows to bypass 2s-granularity limitation
Autotest: update to the new values for the locale
do not expand variables in read()'s file name
remove ability to use break() a block outside any loop
don't add -unix to the qmake command line
Increase the timeout for the QNAM getter test to 30 seconds
Remove unstable hosts from the list
qdoc: Output TOC for more class ref pages.
Other fixes to the remote network stresstester
Fix SSL connection problem.
Make sure we don't try URLs that aren't HTTP or HTTPS
Fix menu bar visibility.
Add SSL remote host tests
Split the remote and the local tests in two, in preparation for SSL tests
Add tests for remote hosts
Change the way we calculate the average transfer rates.
Finish renaming
Move these tests to tests/manual.
Add a QNetworkAccessManager stresstest
Add a non-blocking native function too
...
Diffstat (limited to 'src/gui/kernel/qcursor_mac.mm')
-rw-r--r-- | src/gui/kernel/qcursor_mac.mm | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/gui/kernel/qcursor_mac.mm b/src/gui/kernel/qcursor_mac.mm index 03e38b0..c3d6c54 100644 --- a/src/gui/kernel/qcursor_mac.mm +++ b/src/gui/kernel/qcursor_mac.mm @@ -224,6 +224,15 @@ QPoint QCursor::pos() void QCursor::setPos(int x, int y) { +#ifdef QT_MAC_USE_COCOA + CGPoint pos; + pos.x = x; + pos.y = y; + + CGEventRef e = CGEventCreateMouseEvent(0, kCGEventMouseMoved, pos, 0); + CGEventPost(kCGHIDEventTap, e); + CFRelease(e); +#else CGWarpMouseCursorPosition(CGPointMake(x, y)); /* I'm not too keen on doing this, but this makes it a lot easier, so I just @@ -240,6 +249,7 @@ void QCursor::setPos(int x, int y) QApplication::mouseButtons(), QApplication::keyboardModifiers()); qt_sendSpontaneousEvent(widget, &me); } +#endif } void QCursorData::initCursorFromBitmap() |