Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef CHROME_BROWSER_DOWNLOAD_NOTIFICATION_DOWNLOAD_NOTIFICATION_MANAGER_H_ | |
| 6 #define CHROME_BROWSER_DOWNLOAD_NOTIFICATION_DOWNLOAD_NOTIFICATION_MANAGER_H_ | |
| 7 | |
| 8 #include <set> | |
| 9 | |
| 10 #include "chrome/browser/download/download_ui_controller.h" | |
| 11 #include "chrome/browser/download/notification/download_notification_item.h" | |
| 12 | |
| 13 class Profile; | |
| 14 | |
| 15 class DownloadNotificationManager : public DownloadUIController::Delegate, | |
| 16 public DownloadNotificationItem::Delegate { | |
| 17 public: | |
| 18 explicit DownloadNotificationManager(Profile* profile); | |
| 19 ~DownloadNotificationManager() override; | |
| 20 | |
| 21 // DownloadManager::Observer: | |
|
asanka
2015/01/31 00:38:51
DownloadUIController::Delegate.
yoshiki
2015/02/04 19:03:01
Done.
| |
| 22 void OnNewDownloadReady(content::DownloadItem* item) override; | |
| 23 | |
|
asanka
2015/01/31 00:38:51
// DownloadNotificationItem::Delegate
yoshiki
2015/02/04 19:03:01
Done.
| |
| 24 void OnDownloadNotificationItemDestroying( | |
| 25 DownloadNotificationItem* item) override; | |
| 26 void OnDownloadStarted(DownloadNotificationItem* item) override; | |
| 27 void OnDownloadStopped(DownloadNotificationItem* item) override; | |
| 28 | |
| 29 private: | |
| 30 void UpdateDownloadingMultipleFiles(); | |
| 31 | |
| 32 Profile* profile_; | |
| 33 bool is_downloading_multiple_files_; | |
| 34 std::set<DownloadNotificationItem*> downloading_items_; | |
| 35 std::set<DownloadNotificationItem*> items_; | |
| 36 }; | |
| 37 | |
| 38 #endif // CHROME_BROWSER_DOWNLOAD_NOTIFICATION_DOWNLOAD_NOTIFICATION_MANAGER_H_ | |
| OLD | NEW |