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

Unified Diff: ui/views/bubble/bubble_delegate.cc

Issue 10383236: Revert 137059 - Better fix for closing uber tray when clicking on Desktop (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 7 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 | « ui/views/bubble/bubble_delegate.h ('k') | ui/views/widget/widget.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/bubble/bubble_delegate.cc
===================================================================
--- ui/views/bubble/bubble_delegate.cc (revision 137750)
+++ ui/views/bubble/bubble_delegate.cc (working copy)
@@ -25,7 +25,6 @@
Widget::InitParams bubble_params(Widget::InitParams::TYPE_BUBBLE);
bubble_params.delegate = bubble;
bubble_params.transparent = true;
- bubble_params.close_on_deactivate = bubble->close_on_deactivate();
if (bubble->parent_window())
bubble_params.parent = bubble->parent_window();
else
@@ -213,6 +212,12 @@
}
}
+void BubbleDelegateView::OnWidgetActivationChanged(Widget* widget,
+ bool active) {
+ if (close_on_deactivate() && widget == GetWidget() && !active)
+ GetWidget()->Close();
+}
+
void BubbleDelegateView::OnWidgetMoved(Widget* widget) {
if (move_with_anchor() && anchor_widget() == widget)
SizeToContents();
« no previous file with comments | « ui/views/bubble/bubble_delegate.h ('k') | ui/views/widget/widget.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698