Index: chrome/browser/ui/views/browser_action_view.cc |
diff --git a/chrome/browser/ui/views/browser_action_view.cc b/chrome/browser/ui/views/browser_action_view.cc |
index 7a8a81ef112bd77d42c6ea474a75a621e6945147..05dd725fa2943bce010f65d285ce8e1df938d13c 100644 |
--- a/chrome/browser/ui/views/browser_action_view.cc |
+++ b/chrome/browser/ui/views/browser_action_view.cc |
@@ -314,10 +314,12 @@ bool BrowserActionButton::OnMousePressed(const ui::MouseEvent& event) { |
TextButton::OnMousePressed(event); |
} |
- // See comments in MenuButton::Activate() as to why this is needed. |
- SetMouseHandler(NULL); |
+ if (!views::View::ShouldShowContextMenuOnMousePress()) { |
+ // See comments in MenuButton::Activate() as to why this is needed. |
+ SetMouseHandler(NULL); |
- ShowContextMenu(gfx::Point(), true); |
+ ShowContextMenu(gfx::Point(), true); |
+ } |
return false; |
} |