diff options
author | Ton Roosendaal <ton@blender.org> | 2013-01-05 22:23:05 +0400 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2013-01-05 22:23:05 +0400 |
commit | c6a0818642ed57b8529e4e21f549367fe42cf68f (patch) | |
tree | 3c9e6f01c056285d2b4b715534c29f379e4b55cb /intern/ghost | |
parent | 1005cdc72a3f54554fcb9d8f1172e66492d4f627 (diff) |
Removal of old code trying to detect trackpads.
This was causing error in previous commit "wheel only worked after using trackpad once".
Diffstat (limited to 'intern/ghost')
-rw-r--r-- | intern/ghost/intern/GHOST_SystemCocoa.mm | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/intern/ghost/intern/GHOST_SystemCocoa.mm b/intern/ghost/intern/GHOST_SystemCocoa.mm index d219679f1f9..ef87a498587 100644 --- a/intern/ghost/intern/GHOST_SystemCocoa.mm +++ b/intern/ghost/intern/GHOST_SystemCocoa.mm @@ -574,13 +574,7 @@ GHOST_SystemCocoa::GHOST_SystemCocoa() rstring = (char*)malloc( len ); sysctl( mib, 2, rstring, &len, NULL, 0 ); - //Hack on MacBook revision, as multitouch avail. function missing - //MacbookAir or MacBook version >= 5 (retina is MacBookPro10,1) - if (strstr(rstring,"MacBookAir") || - (strstr(rstring,"MacBook") && (rstring[strlen(rstring)-3]>='5') && (rstring[strlen(rstring)-3]<='9')) || - (strstr(rstring,"MacBook") && (rstring[strlen(rstring)-4]>='1') && (rstring[strlen(rstring)-4]<='9'))) - m_hasMultiTouchTrackpad = true; - else m_hasMultiTouchTrackpad = false; + m_hasMultiTouchTrackpad = false; free( rstring ); rstring = NULL; @@ -1576,6 +1570,8 @@ GHOST_TSuccess GHOST_SystemCocoa::handleMouseEvent(void *eventPtr) } } break; + + /* these events only happen on swiping trackpads */ case NSEventTypeBeginGesture: m_hasMultiTouchTrackpad = 1; break; @@ -1587,7 +1583,7 @@ GHOST_TSuccess GHOST_SystemCocoa::handleMouseEvent(void *eventPtr) { int momentum = [event momentumPhase]; - /* standard scrollwheel case */ + /* standard scrollwheel case, if no swiping happened, and no momentum (kinetic scroll) works */ if (!m_hasMultiTouchTrackpad && momentum == 0) { GHOST_TInt32 delta; |