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

Unified Diff: chrome/browser/download/download_shelf.h

Issue 12995025: [Mac] DownloadShelf should be notified when autoclosing. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 9 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
Index: chrome/browser/download/download_shelf.h
diff --git a/chrome/browser/download/download_shelf.h b/chrome/browser/download/download_shelf.h
index 9bf0ab476476749369c222602fcd8e02685852a5..748ae4fa5dd86a2e2defe59becb9228909bc3de5 100644
--- a/chrome/browser/download/download_shelf.h
+++ b/chrome/browser/download/download_shelf.h
@@ -19,6 +19,11 @@ class Browser;
// implementations.
class DownloadShelf {
public:
+ enum CloseReason {
+ AUTOMATIC,
Nico 2013/03/22 20:24:11 Maybe you can add a comment that explains when AUT
asanka 2013/03/22 21:22:13 Done.
+ USER_ACTION
+ };
+
DownloadShelf();
virtual ~DownloadShelf();
@@ -44,7 +49,7 @@ class DownloadShelf {
void Show();
// Closes the shelf.
- void Close();
+ void Close(CloseReason reason);
// Hides the shelf. This closes the shelf if it is currently showing.
void Hide();
@@ -61,7 +66,7 @@ class DownloadShelf {
protected:
virtual void DoAddDownload(content::DownloadItem* download) = 0;
virtual void DoShow() = 0;
- virtual void DoClose() = 0;
+ virtual void DoClose(CloseReason reason) = 0;
// Time delay to wait before adding a transient download to the shelf.
// Protected virtual for testing.

Powered by Google App Engine
This is Rietveld 408576698