Index: chrome/browser/ui/cocoa/base_bubble_controller.mm |
diff --git a/chrome/browser/ui/cocoa/base_bubble_controller.mm b/chrome/browser/ui/cocoa/base_bubble_controller.mm |
index fad938f381753510dd6ebe7abd54b47d80ef7c56..f08179b252be6a90089e14cb7b474b9b067e1982 100644 |
--- a/chrome/browser/ui/cocoa/base_bubble_controller.mm |
+++ b/chrome/browser/ui/cocoa/base_bubble_controller.mm |
@@ -210,6 +210,11 @@ |
addLocalMonitorForEventsMatchingMask:NSLeftMouseDownMask |
handler:^NSEvent* (NSEvent* event) { |
if (event.window != window) { |
+ // Ignore this event if the window isn't key - in that case, it |
+ // can't resign key status in the first place. |
+ if (![window isKeyWindow]) |
+ return event; |
+ |
// Call via the runloop because this block is called in the |
// middle of event dispatch. |
[self performSelector:@selector(windowDidResignKey:) |