diff options
author | Norwegian Rock Cat <qt-info@nokia.com> | 2009-07-10 14:36:53 (GMT) |
---|---|---|
committer | Norwegian Rock Cat <qt-info@nokia.com> | 2009-07-10 14:37:59 (GMT) |
commit | 577b3d7efc56f23dcf2b377816caa7d1aa3c7f88 (patch) | |
tree | 19c3c7ffba1cee40c5b11121c8d65f7da8eea97a | |
parent | 364aa2a21512d32f3f4271f438e3a6fa799c1e9e (diff) | |
download | Qt-577b3d7efc56f23dcf2b377816caa7d1aa3c7f88.zip Qt-577b3d7efc56f23dcf2b377816caa7d1aa3c7f88.tar.gz Qt-577b3d7efc56f23dcf2b377816caa7d1aa3c7f88.tar.bz2 |
Fix compilation on SnowLeopard
On 64-bit an id (void *) is 64-bit also, so, it really should be a
pointer, but I'll make it a 64-bit int for the time being just so stuff
compiles.
-rw-r--r-- | src/gui/kernel/qmultitouch_mac.mm | 6 | ||||
-rw-r--r-- | src/gui/kernel/qmultitouch_mac_p.h | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/gui/kernel/qmultitouch_mac.mm b/src/gui/kernel/qmultitouch_mac.mm index 3fe85a9..3d2eae6 100644 --- a/src/gui/kernel/qmultitouch_mac.mm +++ b/src/gui/kernel/qmultitouch_mac.mm @@ -48,7 +48,7 @@ QT_BEGIN_NAMESPACE #ifdef QT_MAC_USE_COCOA -QHash<int, QCocoaTouch*> QCocoaTouch::_currentTouches; +QHash<qint64, QCocoaTouch*> QCocoaTouch::_currentTouches; QPointF QCocoaTouch::_screenReferencePos; QPointF QCocoaTouch::_trackpadReferencePos; int QCocoaTouch::_idAssignmentCount = 0; @@ -62,7 +62,7 @@ QCocoaTouch::QCocoaTouch(NSTouch *nstouch) _touchPoint.setId(_idAssignmentCount++); _touchPoint.setPressure(1.0); - _identity = int([nstouch identity]); + _identity = qint64([nstouch identity]); _currentTouches.insert(_identity, this); updateTouchData(nstouch, NSTouchPhaseBegan); } @@ -100,7 +100,7 @@ void QCocoaTouch::updateTouchData(NSTouch *nstouch, NSTouchPhase phase) QCocoaTouch *QCocoaTouch::findQCocoaTouch(NSTouch *nstouch) { - int identity = int([nstouch identity]); + qint64 identity = qint64([nstouch identity]); if (_currentTouches.contains(identity)) return _currentTouches.value(identity); return 0; diff --git a/src/gui/kernel/qmultitouch_mac_p.h b/src/gui/kernel/qmultitouch_mac_p.h index 3fa8f6c..618e9ca 100644 --- a/src/gui/kernel/qmultitouch_mac_p.h +++ b/src/gui/kernel/qmultitouch_mac_p.h @@ -74,7 +74,7 @@ class QCocoaTouch static void setMouseInDraggingState(bool inDraggingState); private: - static QHash<int, QCocoaTouch*> _currentTouches; + static QHash<qint64, QCocoaTouch*> _currentTouches; static QPointF _screenReferencePos; static QPointF _trackpadReferencePos; static int _idAssignmentCount; @@ -82,7 +82,7 @@ class QCocoaTouch static bool _updateInternalStateOnly; QTouchEvent::TouchPoint _touchPoint; - int _identity; + qint64 _identity; QCocoaTouch(NSTouch *nstouch); ~QCocoaTouch(); |