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

Side by Side Diff: chrome/browser/history/most_visited_urls_provider.h

Issue 27047003: Precache tracking database (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@precache
Patch Set: General fixes, added tests, and moved PrecacheManager into component Created 7 years, 2 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
bengr 2013/10/23 19:03:36 2012 -> 2013. Remove the '(c)' too.
sclittle 2013/10/24 22:11:38 Done.
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_HISTORY_MOST_VISITED_URLS_PROVIDER_H_
6 #define CHROME_BROWSER_HISTORY_MOST_VISITED_URLS_PROVIDER_H_
7
8 #include <list>
9
10 #include "base/basictypes.h"
11 #include "base/callback.h"
12 #include "base/compiler_specific.h"
13 #include "base/memory/ref_counted.h"
14 #include "base/memory/weak_ptr.h"
15 #include "chrome/browser/history/history_types.h"
16 #include "components/precache/core/interesting_urls_provider.h"
17 #include "url/gurl.h"
18
19 namespace history {
20
21 class TopSites;
22
23 // An InterestingURLsProvider that provides a list of the user's most visited
bengr 2013/10/23 19:03:36 How about "RepresentativeURLsProvider"? I'm not su
sclittle 2013/10/24 22:11:38 Renamed to URLListProvider.
24 // URLs.
25 class MostVisitedURLsProvider
26 : public precache::InterestingURLsProvider,
27 public base::SupportsWeakPtr<MostVisitedURLsProvider> {
28 public:
29 explicit MostVisitedURLsProvider(TopSites* top_sites);
30 ~MostVisitedURLsProvider();
31
32 virtual void GetInterestingURLs(
33 const base::Callback<void(const std::list<GURL>&)>& callback) OVERRIDE;
34
35 private:
36 void OnMostVisitedURLsReceived(
37 base::Callback<void(const std::list<GURL>&)> callback,
38 const MostVisitedURLList& most_visited_urls);
39
40 scoped_refptr<TopSites> top_sites_;
41
42 DISALLOW_COPY_AND_ASSIGN(MostVisitedURLsProvider);
43 };
44
45 } // namespace history
46
47 #endif // CHROME_BROWSER_HISTORY_MOST_VISITED_URLS_PROVIDER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698