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

Side by Side Diff: chrome/browser/download/download_status_updater.h

Issue 10704052: Download filename determination refactor (3/3) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge with r148594 to and resolve conflicts with r148576 Created 8 years, 5 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_DOWNLOAD_DOWNLOAD_STATUS_UPDATER_H_ 5 #ifndef CHROME_BROWSER_DOWNLOAD_DOWNLOAD_STATUS_UPDATER_H_
6 #define CHROME_BROWSER_DOWNLOAD_DOWNLOAD_STATUS_UPDATER_H_ 6 #define CHROME_BROWSER_DOWNLOAD_DOWNLOAD_STATUS_UPDATER_H_
7 7
8 #include <set> 8 #include <set>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 17 matching lines...) Expand all
28 // Add the specified DownloadManager to the list of managers for which 28 // Add the specified DownloadManager to the list of managers for which
29 // this object reports status. 29 // this object reports status.
30 // The manager must not have previously been added to this updater. 30 // The manager must not have previously been added to this updater.
31 // The updater will automatically disassociate itself from the 31 // The updater will automatically disassociate itself from the
32 // manager when the manager is shutdown. 32 // manager when the manager is shutdown.
33 void AddManager(content::DownloadManager* manager); 33 void AddManager(content::DownloadManager* manager);
34 34
35 // Methods inherited from content::DownloadManager::Observer. 35 // Methods inherited from content::DownloadManager::Observer.
36 virtual void ModelChanged(content::DownloadManager* manager) OVERRIDE; 36 virtual void ModelChanged(content::DownloadManager* manager) OVERRIDE;
37 virtual void ManagerGoingDown(content::DownloadManager* manager) OVERRIDE; 37 virtual void ManagerGoingDown(content::DownloadManager* manager) OVERRIDE;
38 virtual void SelectFileDialogDisplayed(
39 content::DownloadManager* manager, int32 id) OVERRIDE;
40 38
41 // Methods inherited from content::DownloadItem::Observer. 39 // Methods inherited from content::DownloadItem::Observer.
42 virtual void OnDownloadUpdated(content::DownloadItem* download) OVERRIDE; 40 virtual void OnDownloadUpdated(content::DownloadItem* download) OVERRIDE;
43 virtual void OnDownloadOpened(content::DownloadItem* download) OVERRIDE; 41 virtual void OnDownloadOpened(content::DownloadItem* download) OVERRIDE;
44 42
45 protected: 43 protected:
46 // Update the app icon. Virtual to be overridable for testing. 44 // Update the app icon. Virtual to be overridable for testing.
47 virtual void UpdateAppIconDownloadProgress(); 45 virtual void UpdateAppIconDownloadProgress();
48 46
49 private: 47 private:
50 // Update the internal state tracking an item. 48 // Update the internal state tracking an item.
51 void UpdateItem(content::DownloadItem* download); 49 void UpdateItem(content::DownloadItem* download);
52 50
53 std::set<content::DownloadManager*> managers_; 51 std::set<content::DownloadManager*> managers_;
54 std::set<content::DownloadItem*> items_; 52 std::set<content::DownloadItem*> items_;
55 53
56 DISALLOW_COPY_AND_ASSIGN(DownloadStatusUpdater); 54 DISALLOW_COPY_AND_ASSIGN(DownloadStatusUpdater);
57 }; 55 };
58 56
59 #endif // CHROME_BROWSER_DOWNLOAD_DOWNLOAD_STATUS_UPDATER_H_ 57 #endif // CHROME_BROWSER_DOWNLOAD_DOWNLOAD_STATUS_UPDATER_H_
OLDNEW
« no previous file with comments | « chrome/browser/download/download_service.cc ('k') | chrome/browser/download/download_status_updater.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698