Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(753)

Unified Diff: chrome/browser/ui/cocoa/tabs/tab_view.mm

Issue 2314873004: Fix bug that causes spurious tab switches. (Closed)
Patch Set: Comments from rsesek. Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/cocoa/tabs/tab_view.mm
diff --git a/chrome/browser/ui/cocoa/tabs/tab_view.mm b/chrome/browser/ui/cocoa/tabs/tab_view.mm
index 45f042013cd4c9b18d629a8d4f8176810d1b274c..274e5f9764cd7d377b120afaf957e34a72a49c68 100644
--- a/chrome/browser/ui/cocoa/tabs/tab_view.mm
+++ b/chrome/browser/ui/cocoa/tabs/tab_view.mm
@@ -366,15 +366,11 @@ CGFloat LineWidthFromContext(CGContextRef context) {
}
}
- // Fire the action to select the tab.
- [controller_ selectTab:self];
-
- // Messaging the drag controller with |-endDrag:| would seem like the right
- // thing to do here. But, when a tab has been detached, the controller's
- // target is nil until the drag is finalized. Since |-mouseUp:| gets called
- // via the manual event loop inside -[TabStripDragController
- // maybeStartDrag:forTab:], the drag controller can end the dragging session
- // itself directly after calling this.
+ // Except in the rapid tab closure case, mouseDown: triggers a nested run loop
+ // that swallows the mouseUp: event. There's a bug in AppKit that sends
+ // mouseUp: callbacks to inappropriate views, so it's doubly important that
+ // this method doesn't do anything. https://crbug.com/511095.
+ [super mouseUp:theEvent];
}
- (void)otherMouseUp:(NSEvent*)theEvent {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698