summaryrefslogtreecommitdiffstats
path: root/chrome/browser/download/download_status_updater.h
diff options
context:
space:
mode:
authorjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-08-15 21:05:22 +0000
committerjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-08-15 21:05:22 +0000
commit71bf3f5e4b5834e596e8b870088f94246ed3e1d8 (patch)
tree34357b6c720eefebc81008bdd8d8144cd105a02b /chrome/browser/download/download_status_updater.h
parent0da88255cb89cbed89a74befa900082efd2e7a04 (diff)
downloadchromium_src-71bf3f5e4b5834e596e8b870088f94246ed3e1d8.zip
chromium_src-71bf3f5e4b5834e596e8b870088f94246ed3e1d8.tar.gz
chromium_src-71bf3f5e4b5834e596e8b870088f94246ed3e1d8.tar.bz2
Move the core download files to content.
Review URL: http://codereview.chromium.org/7618048 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@96829 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/download/download_status_updater.h')
-rw-r--r--chrome/browser/download/download_status_updater.h47
1 files changed, 0 insertions, 47 deletions
diff --git a/chrome/browser/download/download_status_updater.h b/chrome/browser/download/download_status_updater.h
deleted file mode 100644
index dda8f15..0000000
--- a/chrome/browser/download/download_status_updater.h
+++ /dev/null
@@ -1,47 +0,0 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef CHROME_BROWSER_DOWNLOAD_DOWNLOAD_STATUS_UPDATER_H_
-#define CHROME_BROWSER_DOWNLOAD_DOWNLOAD_STATUS_UPDATER_H_
-
-#include <set>
-
-#include "base/basictypes.h"
-#include "base/gtest_prod_util.h"
-#include "base/memory/weak_ptr.h"
-
-class DownloadStatusUpdaterDelegate;
-
-// Keeps track of download progress for the entire browser.
-class DownloadStatusUpdater
- : public base::SupportsWeakPtr<DownloadStatusUpdater> {
- public:
- DownloadStatusUpdater();
- ~DownloadStatusUpdater();
-
- void AddDelegate(DownloadStatusUpdaterDelegate* delegate);
- void RemoveDelegate(DownloadStatusUpdaterDelegate* delegate);
-
- // Updates the download status based on data from delegates.
- void Update();
-
- private:
- FRIEND_TEST_ALL_PREFIXES(DownloadStatusUpdaterTest, Basic);
- FRIEND_TEST_ALL_PREFIXES(DownloadStatusUpdaterTest, OneDelegate);
- FRIEND_TEST_ALL_PREFIXES(DownloadStatusUpdaterTest, MultipleDelegates);
-
- // If the progress is known (i.e. we know the final size of all downloads),
- // returns true and puts a percentage (in range [0-1]) in |progress|.
- bool GetProgress(float* progress);
-
- // Returns the number of downloads that are in progress.
- int64 GetInProgressDownloadCount();
-
- typedef std::set<DownloadStatusUpdaterDelegate*> DelegateSet;
- DelegateSet delegates_;
-
- DISALLOW_COPY_AND_ASSIGN(DownloadStatusUpdater);
-};
-
-#endif // CHROME_BROWSER_DOWNLOAD_DOWNLOAD_STATUS_UPDATER_H_