summaryrefslogtreecommitdiffstats
path: root/chrome/browser/views/browser_bubble_gtk.cc
diff options
context:
space:
mode:
authorjcampan@chromium.org <jcampan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-03-15 21:03:13 +0000
committerjcampan@chromium.org <jcampan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-03-15 21:03:13 +0000
commite00e18af2f61e8eec071778f66ef15e8bf671d42 (patch)
treeae6a8d76011d08df79e2e7e3c22bb3440c822973 /chrome/browser/views/browser_bubble_gtk.cc
parentf9a88c50069a49d1314a755dd2aac3812c23659d (diff)
downloadchromium_src-e00e18af2f61e8eec071778f66ef15e8bf671d42.zip
chromium_src-e00e18af2f61e8eec071778f66ef15e8bf671d42.tar.gz
chromium_src-e00e18af2f61e8eec071778f66ef15e8bf671d42.tar.bz2
Making browser bubble notifies to its delegate whether it
lost focus to a child window. This is used to prevent closing browser/page action bubble when they lose focus to a select popup or alert box. BUG=37784 TEST=Start Chrome with extensions that have a page action and browser action that contains selects (combobox) and a way to show an alert box. Verify that showing the select popup or the alert dialog does not cause the bubble to close. Review URL: http://codereview.chromium.org/899002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@41630 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/views/browser_bubble_gtk.cc')
-rw-r--r--chrome/browser/views/browser_bubble_gtk.cc9
1 files changed, 6 insertions, 3 deletions
diff --git a/chrome/browser/views/browser_bubble_gtk.cc b/chrome/browser/views/browser_bubble_gtk.cc
index cf2ff0c..8fdedb8 100644
--- a/chrome/browser/views/browser_bubble_gtk.cc
+++ b/chrome/browser/views/browser_bubble_gtk.cc
@@ -34,7 +34,7 @@ class BubbleWidget : public views::WidgetGtk {
if (IsActive()) {
BrowserBubble::Delegate* delegate = bubble_->delegate();
if (delegate)
- delegate->BubbleLostFocus(bubble_, NULL);
+ delegate->BubbleLostFocus(bubble_, false);
}
views::WidgetGtk::Close();
}
@@ -43,7 +43,7 @@ class BubbleWidget : public views::WidgetGtk {
if (IsActive()) {
BrowserBubble::Delegate* delegate = bubble_->delegate();
if (delegate)
- delegate->BubbleLostFocus(bubble_, NULL);
+ delegate->BubbleLostFocus(bubble_, false);
}
views::WidgetGtk::Hide();
}
@@ -58,7 +58,10 @@ class BubbleWidget : public views::WidgetGtk {
return;
}
- delegate->BubbleLostFocus(bubble_, GetNativeView());
+ // TODO(jcampan): http://crbugs.com/29131 Check if the window we are losing
+ // focus to is a child window and pass that to the call
+ // below.
+ delegate->BubbleLostFocus(bubble_, false);
}
virtual gboolean OnFocusIn(GtkWidget* widget, GdkEventFocus* event) {