diff options
author | thakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-04 03:30:22 +0000 |
---|---|---|
committer | thakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-04 03:30:22 +0000 |
commit | 59560e0ba999d5edc33453d4a0fbf44831025817 (patch) | |
tree | f365944f6f0eca593a28747a7fed4caf169578fb /chrome/browser/gtk/download_shelf_gtk.h | |
parent | 4d2868972ff25746d39ecea58e88480ae0463145 (diff) | |
download | chromium_src-59560e0ba999d5edc33453d4a0fbf44831025817.zip chromium_src-59560e0ba999d5edc33453d4a0fbf44831025817.tar.gz chromium_src-59560e0ba999d5edc33453d4a0fbf44831025817.tar.bz2 |
Move download shelf from per-tab to per-window. Also disable auto-hiding of
the shelf.
BUG=9025
TEST=Download file in one tab, open new tab, and check that download shelf is
still open. Also try the shelf's close button and the "show all downloads"
link. When saving a file, the download animation should not show up.
Review URL: http://codereview.chromium.org/115740
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17595 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/gtk/download_shelf_gtk.h')
-rw-r--r-- | chrome/browser/gtk/download_shelf_gtk.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/chrome/browser/gtk/download_shelf_gtk.h b/chrome/browser/gtk/download_shelf_gtk.h index 4ed81b7..afafd27 100644 --- a/chrome/browser/gtk/download_shelf_gtk.h +++ b/chrome/browser/gtk/download_shelf_gtk.h @@ -9,18 +9,20 @@ #include <vector> +#include "base/gfx/native_widget_types.h" #include "base/scoped_ptr.h" #include "chrome/browser/download/download_shelf.h" #include "chrome/common/owned_widget_gtk.h" class BaseDownloadItemModel; +class Browser; class CustomDrawButton; class DownloadItemGtk; class SlideAnimatorGtk; class DownloadShelfGtk : public DownloadShelf { public: - explicit DownloadShelfGtk(TabContents* tab_contents); + explicit DownloadShelfGtk(Browser* browser, gfx::NativeView view); ~DownloadShelfGtk(); @@ -28,6 +30,11 @@ class DownloadShelfGtk : public DownloadShelf { virtual void AddDownload(BaseDownloadItemModel* download_model); virtual bool IsShowing() const; virtual bool IsClosing() const; + virtual void Show(); + virtual void Close(); + + // Returns the current height of the shelf. + int GetHeight() const; private: // Remove |download_item| from the download shelf and delete it. @@ -45,7 +52,7 @@ class DownloadShelfGtk : public DownloadShelf { scoped_ptr<SlideAnimatorGtk> slide_widget_; // |hbox_| holds the download items and buttons of the shelf. - GtkWidget* hbox_; + OwnedWidgetGtk hbox_; // |shelf_| is the second highest level widget. See the constructor // for an explanation of the widget layout. |