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

Unified Diff: chrome/browser/ui/webui/downloads_dom_handler.h

Issue 966983002: downloads: clicking "remove" on chrome://downloads should also hide shelf item. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: +tests Created 5 years, 10 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/ui/webui/downloads_dom_handler.h
diff --git a/chrome/browser/ui/webui/downloads_dom_handler.h b/chrome/browser/ui/webui/downloads_dom_handler.h
index 06890acdcb06079d2493cc3b2056eb980b560c7a..85fdbd8a792d3514b631a9988c94df9690134c81 100644
--- a/chrome/browser/ui/webui/downloads_dom_handler.h
+++ b/chrome/browser/ui/webui/downloads_dom_handler.h
@@ -106,6 +106,9 @@ class DownloadsDOMHandler : public content::WebUIMessageHandler,
// Protected for testing.
virtual content::DownloadManager* GetMainNotifierManager();
+ // Actually remove downloads with an ID in |removals_|. This cannot be undone.
+ void FinalizeRemovals();
+
private:
// Shorthand for |observing_items_|, which tracks all items that this is
// observing so that RemoveObserver will be called for all of them.
@@ -150,7 +153,7 @@ class DownloadsDOMHandler : public content::WebUIMessageHandler,
scoped_ptr<AllDownloadItemNotifier> original_notifier_;
// IDs of downloads to remove when this handler gets deleted.
- std::vector<std::set<uint32>> removes_;
+ std::vector<std::set<uint32>> removals_;
// Whether a call to SendCurrentDownloads() is currently scheduled.
bool update_scheduled_;
« no previous file with comments | « chrome/browser/ui/views/download/download_shelf_view.cc ('k') | chrome/browser/ui/webui/downloads_dom_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698