From 9c429ac63c417c61397fd5d14f032b0fa400937e Mon Sep 17 00:00:00 2001 From: Manolo Gouy Date: Wed, 21 Sep 2016 06:10:06 +0000 Subject: [PATCH] Remove the 'suppressed' variable from cocoaMouseHandler(), a useless residue from ancient code. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11959 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- src/Fl_cocoa.mm | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/src/Fl_cocoa.mm b/src/Fl_cocoa.mm index c7bc89fd0..82d04fb61 100644 --- a/src/Fl_cocoa.mm +++ b/src/Fl_cocoa.mm @@ -1064,7 +1064,6 @@ static void cocoaMouseHandler(NSEvent *theEvent) { static int keysym[] = { 0, FL_Button+1, FL_Button+3, FL_Button+2 }; static int px, py; - static char suppressed = 0; fl_lock_function(); @@ -1097,7 +1096,6 @@ static void cocoaMouseHandler(NSEvent *theEvent) case NSLeftMouseDown: case NSRightMouseDown: case NSOtherMouseDown: - suppressed = 0; sendEvent = FL_PUSH; Fl::e_is_click = 1; px = (int)pos.x; py = (int)pos.y; @@ -1109,10 +1107,6 @@ static void cocoaMouseHandler(NSEvent *theEvent) case NSLeftMouseUp: case NSRightMouseUp: case NSOtherMouseUp: - if (suppressed) { - suppressed = 0; - break; - } if ( !window ) break; if ( !sendEvent ) { sendEvent = FL_RELEASE; @@ -1120,15 +1114,13 @@ static void cocoaMouseHandler(NSEvent *theEvent) Fl::e_keysym = keysym[ btn ]; // fall through case NSMouseMoved: - suppressed = 0; - if ( !sendEvent ) { + if ( !sendEvent ) { sendEvent = FL_MOVE; } // fall through case NSLeftMouseDragged: case NSRightMouseDragged: case NSOtherMouseDragged: { - if (suppressed) break; if ( !sendEvent ) { sendEvent = FL_MOVE; // Fl::handle will convert into FL_DRAG if (fabs(pos.x-px)>5 || fabs(pos.y-py)>5)