diff options
author | benjhayden@chromium.org <benjhayden@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-11-20 00:52:08 +0000 |
---|---|---|
committer | benjhayden@chromium.org <benjhayden@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-11-20 00:52:08 +0000 |
commit | 3d95e54652070dacfdb9188c3f6f48111bcc007e (patch) | |
tree | 7ad31f4dbdb170fc30cc00ce2b31d76ce146799d /chrome/browser/download/download_service.h | |
parent | 8b9d8f76949307b91f6399d452e41de59f2cbce6 (diff) | |
download | chromium_src-3d95e54652070dacfdb9188c3f6f48111bcc007e.zip chromium_src-3d95e54652070dacfdb9188c3f6f48111bcc007e.tar.gz chromium_src-3d95e54652070dacfdb9188c3f6f48111bcc007e.tar.bz2 |
Make DownloadHistory observe manager, items
Rip out half of DownloadManagerDelegate.
Make DownloadManager create persisted DownloadItems one at a time and return them to DownloadHistory.
Move DownloadPersistentStoreInfo from content to chrome.
Kill DownloadDatabase::CheckThread(). (Leftover from 85408.)
Change DownloadDatabase::RemoveDownloads() to take an explicit set of db_handles.
Merge DownloadDatabase::UpdateDownload[Path]().
After this CL, I'll send out another one to remove the usage of CancelableRequest from the downloads-specific HistoryService APIs.
BUG=154309
Review URL: https://chromiumcodereview.appspot.com/10915180
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@168670 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/download/download_service.h')
-rw-r--r-- | chrome/browser/download/download_service.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/chrome/browser/download/download_service.h b/chrome/browser/download/download_service.h index 24535f9..1c72b29 100644 --- a/chrome/browser/download/download_service.h +++ b/chrome/browser/download/download_service.h @@ -10,9 +10,11 @@ #include "base/basictypes.h" #include "base/callback_forward.h" #include "base/memory/ref_counted.h" +#include "base/memory/scoped_ptr.h" #include "chrome/browser/profiles/profile_keyed_service.h" class ChromeDownloadManagerDelegate; +class DownloadHistory; class Profile; namespace content { @@ -28,6 +30,11 @@ class DownloadService : public ProfileKeyedService { // Get the download manager delegate, creating it if it doesn't already exist. ChromeDownloadManagerDelegate* GetDownloadManagerDelegate(); + // Get the interface to the history system. Returns NULL if profile is + // incognito or if the DownloadManager hasn't been created yet or if there is + // no HistoryService for profile. + DownloadHistory* GetDownloadHistory(); + // Has a download manager been created? bool HasCreatedDownloadManager(); @@ -56,6 +63,8 @@ class DownloadService : public ProfileKeyedService { // callbacks. scoped_refptr<ChromeDownloadManagerDelegate> manager_delegate_; + scoped_ptr<DownloadHistory> download_history_; + DISALLOW_COPY_AND_ASSIGN(DownloadService); }; |