Chromium Code Reviews| Index: chrome/browser/history/history_service.h |
| diff --git a/chrome/browser/history/history_service.h b/chrome/browser/history/history_service.h |
| index b2c05ca9210b418f56699e723d3a5ad1d45e5503..a9753401bb966ad3fe1faeed1e4d29cb600cbd64 100644 |
| --- a/chrome/browser/history/history_service.h |
| +++ b/chrome/browser/history/history_service.h |
| @@ -41,6 +41,7 @@ |
| #if defined(OS_ANDROID) |
| class AndroidHistoryProviderService; |
| #endif |
| + |
| class BookmarkService; |
| class GURL; |
| class HistoryURLProvider; |
| @@ -62,6 +63,7 @@ class VisitedLinkMaster; |
| namespace history { |
| class HistoryBackend; |
| +class HistoryClient; |
| class HistoryDatabase; |
| class HistoryDBTask; |
| class HistoryQueryTest; |
| @@ -85,14 +87,13 @@ struct HistoryDetails; |
| class HistoryService : public CancelableRequestProvider, |
| public content::NotificationObserver, |
| public syncer::SyncableService, |
| - public KeyedService, |
| public visitedlink::VisitedLinkDelegate { |
| public: |
| // Miscellaneous commonly-used types. |
| typedef std::vector<PageUsageData*> PageUsageDataList; |
| // Must call Init after construction. |
|
blundell
2014/05/27 09:56:38
add a comment about expected lifetime.
sdefresne
2014/05/28 17:10:42
Done.
|
| - explicit HistoryService(Profile* profile); |
| + explicit HistoryService(history::HistoryClient* client, Profile* profile); |
| // The empty constructor is provided only for testing. |
| HistoryService(); |
| @@ -164,8 +165,7 @@ class HistoryService : public CancelableRequestProvider, |
| return in_memory_url_index_.get(); |
| } |
| - // KeyedService: |
| - virtual void Shutdown() OVERRIDE; |
| + void Shutdown(); |
| // Navigation ---------------------------------------------------------------- |
| @@ -562,6 +562,9 @@ class HistoryService : public CancelableRequestProvider, |
| // history. We filter out some URLs such as JavaScript. |
| static bool CanAddURL(const GURL& url); |
| + // Returns the HistoryClient. |
| + history::HistoryClient* history_client() const { return history_client_; } |
|
blundell
2014/05/27 09:56:38
same comment about const.
sdefresne
2014/05/28 17:10:42
Done.
|
| + |
| base::WeakPtr<HistoryService> AsWeakPtr(); |
| // syncer::SyncableService implementation. |
| @@ -1019,6 +1022,9 @@ class HistoryService : public CancelableRequestProvider, |
| // TODO(mrossetti): Consider changing ownership. See http://crbug.com/138321 |
| scoped_ptr<history::InMemoryHistoryBackend> in_memory_backend_; |
| + // The HistoryClient; may be NULL in tests. |
|
blundell
2014/05/27 09:56:38
add a comment about expected lifetime.
sdefresne
2014/05/28 17:10:42
Done.
|
| + history::HistoryClient* history_client_; |
| + |
| // The profile, may be null when testing. |
| Profile* profile_; |