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
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2012-05-07 17:42:25 +0400
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2012-05-07 17:42:25 +0400
commitb613879f348e870d3b0fb6a68bbcf91e85579280 (patch)
tree963eee4e51b09b3f73a3a6e4f45ad571d4b29f3c /intern/ghost
parent97df6dab2fa2da856ee4c096ed94a9569a9e5abc (diff)
GHOST/Cocoa: revert tablet detection commit for continuous grab, apparently it is
already doing it and this change breaks something? Still it seems strange that it is doing tablet stuff in this part of the code then.
Diffstat (limited to 'intern/ghost')
-rw-r--r--intern/ghost/intern/GHOST_SystemCocoa.mm14
1 files changed, 8 insertions, 6 deletions
diff --git a/intern/ghost/intern/GHOST_SystemCocoa.mm b/intern/ghost/intern/GHOST_SystemCocoa.mm
index 8baf3a12c16..6013f3519ec 100644
--- a/intern/ghost/intern/GHOST_SystemCocoa.mm
+++ b/intern/ghost/intern/GHOST_SystemCocoa.mm
@@ -1450,8 +1450,6 @@ GHOST_TSuccess GHOST_SystemCocoa::handleMouseEvent(void *eventPtr)
return GHOST_kFailure;
}
- bool is_tablet = false;
-
switch ([event type])
{
case NSLeftMouseDown:
@@ -1459,7 +1457,7 @@ GHOST_TSuccess GHOST_SystemCocoa::handleMouseEvent(void *eventPtr)
case NSOtherMouseDown:
pushEvent(new GHOST_EventButton([event timestamp]*1000, GHOST_kEventButtonDown, window, convertButton([event buttonNumber])));
//Handle tablet events combined with mouse events
- is_tablet = handleTabletEvent(event);
+ handleTabletEvent(event);
break;
case NSLeftMouseUp:
@@ -1467,21 +1465,25 @@ GHOST_TSuccess GHOST_SystemCocoa::handleMouseEvent(void *eventPtr)
case NSOtherMouseUp:
pushEvent(new GHOST_EventButton([event timestamp]*1000, GHOST_kEventButtonUp, window, convertButton([event buttonNumber])));
//Handle tablet events combined with mouse events
- is_tablet = handleTabletEvent(event);
+ handleTabletEvent(event);
break;
case NSLeftMouseDragged:
case NSRightMouseDragged:
case NSOtherMouseDragged:
//Handle tablet events combined with mouse events
- is_tablet = handleTabletEvent(event);
+ handleTabletEvent(event);
case NSMouseMoved:
{
GHOST_TGrabCursorMode grab_mode = window->getCursorGrabMode();
- if (is_tablet && window->getCursorGrabModeIsWarp())
+ /* TODO: CHECK IF THIS IS A TABLET EVENT */
+ bool is_tablet = false;
+
+ if (is_tablet && window->getCursorGrabModeIsWarp()) {
grab_mode = GHOST_kGrabDisable;
+ }
switch (grab_mode) {
case GHOST_kGrabHide: //Cursor hidden grab operation : no cursor move