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

Unified Diff: chrome/browser/ui/gtk/infobars/infobar_gtk.cc

Issue 6932002: gtk/infobars: Refactor AnimateOpen/Open into a single Show() method. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 8 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 | « chrome/browser/ui/gtk/infobars/infobar_gtk.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/gtk/infobars/infobar_gtk.cc
diff --git a/chrome/browser/ui/gtk/infobars/infobar_gtk.cc b/chrome/browser/ui/gtk/infobars/infobar_gtk.cc
index 7ed90225ada93860c46a8692c4706283825f69d7..f74c8cb5acb061444971fa5d9820477618e6a695 100644
--- a/chrome/browser/ui/gtk/infobars/infobar_gtk.cc
+++ b/chrome/browser/ui/gtk/infobars/infobar_gtk.cc
@@ -95,16 +95,11 @@ GtkWidget* InfoBar::widget() {
return slide_widget_->widget();
}
-void InfoBar::AnimateOpen() {
- slide_widget_->Open();
-
- gtk_widget_show_all(bg_box_);
- if (bg_box_->window)
- gdk_window_lower(bg_box_->window);
-}
-
-void InfoBar::Open() {
- slide_widget_->OpenWithoutAnimation();
+void InfoBar::Show(bool animate) {
+ if (animate)
+ slide_widget_->Open();
+ else
+ slide_widget_->OpenWithoutAnimation();
gtk_widget_show_all(bg_box_);
if (bg_box_->window)
« no previous file with comments | « chrome/browser/ui/gtk/infobars/infobar_gtk.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698