File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -128,7 +128,10 @@ - (void)_recordNewTouches:(NSSet *)touches
128128#else // [TODO(macOS ISS#2323203)
129129 CGPoint touchLocation = [self .view convertPoint: touch.locationInWindow fromView: nil ];
130130 NSView *targetView = [self .view hitTest: touchLocation];
131- if ([targetView isKindOfClass: NSText .class]) {
131+ // Pair the mouse down events with mouse up events so our _nativeTouches cache doesn't get stale
132+ if ([targetView isKindOfClass: [NSControl class ]]) {
133+ _shouldSendMouseUpOnSystemBehalf = [(NSControl *)targetView isEnabled ];
134+ } else if ([targetView isKindOfClass: [NSText class ]]) {
132135 _shouldSendMouseUpOnSystemBehalf = [(NSText *)targetView isSelectable ];
133136 } else {
134137 _shouldSendMouseUpOnSystemBehalf = NO ;
You can’t perform that action at this time.
0 commit comments