Buggy code:
event . detail = SWT . ARROW ; event . x = ( ( int ) ( pt . x ) ) ; event . y = ( ( int ) ( pt . y ) ) ; postEvent ( Selection , event ) ; } } else { int sizeof = org . eclipse . swt . internal . carbon . Point . sizeof ; org . eclipse . swt . internal . carbon . Point pt = new org . eclipse . swt . internal . carbon . Point ( ) ; OS . GetEventParameter ( theEvent , kEventParamMouseLocation , typeQDPoint , null , sizeof , null , pt ) ; Rect rect = new Rect ( ) ; int window = OS . GetControlOwner ( handle ) ; OS . GetWindowBounds ( window , ( ( short ) ( kWindowContentRgn ) ) , rect ) ; int x = ( pt . h ) - ( rect . left ) ; int y = ( pt . v ) - ( rect . top ) ; OS . GetControlBounds ( handle , rect ) ; x -= rect . left ; y -= rect . top ; int width = ( rect . right ) - ( rect . left ) ; if ( ( width - x ) < 12 ) { x = rect . left ; y = rect . bottom ; OS . GetControlBounds ( parent . handle , rect ) ; x -= rect . left ; y -= rect . top ; Event event = new Event ( ) ; event . detail = SWT . ARROW ; event . x = x ; event . y = y ; postEvent ( Selection , event ) ; } } } display . grabControl = null ; display . runDeferredEvents ( ) ; tracking = false ; result = OS . CallNextEventHandler ( nextHandler , theEvent ) ; if ( tracking ) { if ( ( OS . HIVIEW ) && ( ( text . length ( ) ) > 0 ) ) { partCode = 0 ; if ( ( labelHandle ) != 0 ) redrawWidget ( labelHandle , false ) ; if ( ( ( image ) != null ) && ( ( iconHandle ) != 0 ) ) { OS . SetControlData ( iconHandle , kControlEntireControl , kControlIconTransformTag , 2 , new short [ ] { ( ( short ) ( 0 ) ) } ) ; redrawWidget ( iconHandle , false ) ; } } org . eclipse . swt . internal . carbon . Point outPt = new org . eclipse . swt . internal . carbon . Point ( ) ; OS . GetGlobalMouse ( outPt ) ; Rect rect = new Rect ( ) ; int window = OS . GetControlOwner ( handle ) ; int x ; int y ; if ( OS . HIVIEW ) { CGPoint pt = new CGPoint ( ) ; pt . x = outPt . h ; pt . y = outPt . v ; OS . HIViewConvertPoint ( pt , 0 , parent . handle ) ; x = ( ( int ) ( pt . x ) ) ; y = ( ( int ) ( pt . y ) ) ; OS . GetWindowBounds ( window , ( ( short ) ( kWindowStructureRgn ) ) , rect ) ; } else { OS . GetControlBounds ( parent . handle , rect ) ; x = ( outPt . h ) - ( rect . left ) ; y = ( outPt . v ) - ( rect . top ) ; OS . GetWindowBounds ( window , ( ( short ) ( kWindowContentRgn ) ) , rect ) ; } x -= rect . left ; y -= rect . top ; short [ ] button = new short [ 1 ] ; OS . GetEventParameter ( theEvent , kEventParamMouseButton , typeMouseButton , null , 2 , null , button ) ; int chord = OS . GetCurrentEventButtonState ( ) ; int modifiers = OS . GetCurrentEventKeyModifiers ( ) ; <START_BUG> parent . sendMouseEvent ( MouseUp , button [ 0 ] , chord , ( ( short ) ( x ) ) , ( ( short ) ( y ) ) , modifiers , true ) ; <END_BUG> } tracking = false ; return result ; } int kEventMouseDragged ( int nextHandler , int theEvent , int userData ) { } int kEventMouseMoved ( int nextHandler , int theEvent , int userData ) { } int kEventMouseUp ( int nextHandler , int theEvent , int userData ) { } void register ( ) { } void releaseParent ( ) { } void releaseHandle ( ) { } void releaseWidget ( ) { } public void removeSelectionListener ( SelectionListener listener ) { } void resetVisibleRegion ( int control ) { } void selectRadio ( ) { } void setBackground ( float [ ] color ) { } void setBounds ( int x , int y , int width , int height ) { } public void setControl ( Control control ) { } public void setEnabled ( boolean enabled ) { } void setFontStyle ( Font font ) { } void setForeground ( float [ ] color ) { } public void setDisabledImage ( Image image ) { } public void setHotImage ( Image image ) { } public void setImage ( Image image ) { } boolean setRadioSelection ( boolean value ) { } public void setSelection ( boolean selected ) { } public void setText ( String string ) { } public void setToolTipText ( String string ) { } public void setWidth ( int width ) { } void setZOrder ( ) { } void updateImage ( boolean layout ) { } void updateText ( boolean layout ) { } Point textExtent ( ) { } }

Fix:
parent . sendMouseEvent ( MouseUp , button [ 0 ] , true , chord , ( ( short ) ( x ) ) , ( ( short ) ( y ) ) , modifiers ) ;