Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/intern
diff options
context:
space:
mode:
authorTon Roosendaal <ton@blender.org>2012-12-30 14:38:56 +0400
committerTon Roosendaal <ton@blender.org>2012-12-30 14:38:56 +0400
commitfde101c50c3d7ad6bb43a578d7622cea084001a3 (patch)
treea25be1065421abe82545763024a09b2cf977af14 /intern
parentb3d365289f379ea6838432d7131458a6dce5ceea (diff)
Revert change from Jens, wrong pointer check in the code.
That change made all scrollwheel events be handled as if it was a swipe gesture. Old style mouse wheel didn't work anymore. This version should work for everyone, but we need more mac testers :)
Diffstat (limited to 'intern')
-rw-r--r--intern/ghost/intern/GHOST_SystemCocoa.mm14
1 files changed, 4 insertions, 10 deletions
diff --git a/intern/ghost/intern/GHOST_SystemCocoa.mm b/intern/ghost/intern/GHOST_SystemCocoa.mm
index d88b90d8f05..2d9d89d9ad0 100644
--- a/intern/ghost/intern/GHOST_SystemCocoa.mm
+++ b/intern/ghost/intern/GHOST_SystemCocoa.mm
@@ -1577,21 +1577,15 @@ GHOST_TSuccess GHOST_SystemCocoa::handleMouseEvent(void *eventPtr)
}
break;
- case NSEventTypeBeginGesture:
- m_hasMultiTouchTrackpad = true;
- break;
- case NSEventTypeEndGesture:
- m_hasMultiTouchTrackpad = false;
- break;
-
case NSScrollWheel:
{
int momentum = 0;
#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1070
- momentum = [event momentumPhase];
+ m_hasMultiTouchTrackpad = 0;
+ momentum = [event momentumPhase] || [event phase];
#endif
- /* standard scrollwheel case, NULL check address !!! of momentum */
- if (!m_hasMultiTouchTrackpad && &momentum == NULL) {
+ /* standard scrollwheel case */
+ if (!m_hasMultiTouchTrackpad && momentum == 0) {
GHOST_TInt32 delta;
double deltaF = [event deltaY];