diff options
author | estade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-04-21 17:12:53 +0000 |
---|---|---|
committer | estade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-04-21 17:12:53 +0000 |
commit | 08f75ed78a7f1823b850aa8cc0c90d4f760fc6ca (patch) | |
tree | f2ac1138b71e215c89d27926a440d8516562e38f /chrome/browser/gtk/infobar_container_gtk.cc | |
parent | 9bf98f6112f3780034f8e8e3914f08ac7e5fabd5 (diff) | |
download | chromium_src-08f75ed78a7f1823b850aa8cc0c90d4f760fc6ca.zip chromium_src-08f75ed78a7f1823b850aa8cc0c90d4f760fc6ca.tar.gz chromium_src-08f75ed78a7f1823b850aa8cc0c90d4f760fc6ca.tar.bz2 |
Add open/close animations to infobar, download shelf.
Animations are implemented by packing the native widget structure into a GtkFixed which resizes and moves its contents around based on AnimationDelegate callbacks.
Review URL: http://codereview.chromium.org/88005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@14116 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/gtk/infobar_container_gtk.cc')
-rw-r--r-- | chrome/browser/gtk/infobar_container_gtk.cc | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/chrome/browser/gtk/infobar_container_gtk.cc b/chrome/browser/gtk/infobar_container_gtk.cc index b30333e..f560ca1 100644 --- a/chrome/browser/gtk/infobar_container_gtk.cc +++ b/chrome/browser/gtk/infobar_container_gtk.cc @@ -28,11 +28,16 @@ void AnimateClosingForDelegate(GtkWidget* infobar_widget, RemoveInfoBarData* data = reinterpret_cast<RemoveInfoBarData*>(remove_info_bar_data); + if (!infobar) { + NOTREACHED(); + return; + } + if (data->delegate == infobar->delegate()) - gtk_container_remove(GTK_CONTAINER(data->container), infobar_widget); + infobar->AnimateClose(); } -} +} // namespace // InfoBarContainerGtk, public: ------------------------------------------------ |