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

Unified Diff: chrome/browser/browsing_data/history_counter.h

Issue 2084903002: Moved BrowsingDataCounter and part of BrowsingDataCounterUtils to components. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/browsing_data/history_counter.h
diff --git a/chrome/browser/browsing_data/history_counter.h b/chrome/browser/browsing_data/history_counter.h
index 1fb8c589a8786617b32bbe55c3db037f9c15ec77..84acac9a62dcfa5ef227e8e8f363c4cc120e2433 100644
--- a/chrome/browser/browsing_data/history_counter.h
+++ b/chrome/browser/browsing_data/history_counter.h
@@ -8,15 +8,17 @@
#include "base/memory/weak_ptr.h"
#include "base/task/cancelable_task_tracker.h"
#include "base/timer/timer.h"
-#include "chrome/browser/browsing_data/browsing_data_counter.h"
+#include "components/browsing_data/counters/browsing_data_counter.h"
#include "components/history/core/browser/history_service.h"
#include "components/history/core/browser/web_history_service.h"
#include "components/sync_driver/sync_service_observer.h"
+class Profile;
+
class ProfileSyncService;
-class HistoryCounter: public BrowsingDataCounter,
- public sync_driver::SyncServiceObserver {
+class HistoryCounter : public browsing_data::BrowsingDataCounter,
+ public sync_driver::SyncServiceObserver {
public:
class HistoryResult : public FinishedResult {
public:
@@ -31,11 +33,10 @@ class HistoryCounter: public BrowsingDataCounter,
bool has_synced_visits_;
};
- HistoryCounter();
+ explicit HistoryCounter(Profile* profile);
~HistoryCounter() override;
void OnInitialized() override;
- const std::string& GetPrefName() const override;
// Whether there are counting tasks in progress. Only used for testing.
bool HasTrackedTasks();
@@ -45,7 +46,7 @@ class HistoryCounter: public BrowsingDataCounter,
void SetWebHistoryServiceForTesting(history::WebHistoryService* service);
private:
- const std::string pref_name_;
+ Profile* profile_;
BrowsingDataCounter::ResultInt local_result_;
bool has_synced_visits_;
« no previous file with comments | « chrome/browser/browsing_data/downloads_counter_browsertest.cc ('k') | chrome/browser/browsing_data/history_counter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698