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

Side by Side Diff: chrome/browser/android/ntp/most_visited_sites.h

Issue 2000653002: Replace the usage of SkBitmap with gfx::Image in the suggestion service. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: accidental up load. This patchset was not committed with this CL Created 4 years, 6 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
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef COMPONENTS_NTP_TILES_MOST_VISITED_SITES_H_ 5 #ifndef CHROME_BROWSER_ANDROID_NTP_MOST_VISITED_SITES_H_
6 #define COMPONENTS_NTP_TILES_MOST_VISITED_SITES_H_ 6 #define CHROME_BROWSER_ANDROID_NTP_MOST_VISITED_SITES_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <memory> 10 #include <memory>
11 #include <string> 11 #include <string>
12 #include <vector> 12 #include <vector>
13 13
14 #include "base/compiler_specific.h" 14 #include "base/compiler_specific.h"
15 #include "base/files/file_path.h" 15 #include "base/files/file_path.h"
16 #include "base/macros.h" 16 #include "base/macros.h"
17 #include "base/memory/weak_ptr.h" 17 #include "base/memory/weak_ptr.h"
18 #include "base/scoped_observer.h" 18 #include "base/scoped_observer.h"
19 #include "chrome/browser/android/ntp/popular_sites.h"
19 #include "components/history/core/browser/history_types.h" 20 #include "components/history/core/browser/history_types.h"
20 #include "components/history/core/browser/top_sites_observer.h" 21 #include "components/history/core/browser/top_sites_observer.h"
21 #include "components/ntp_tiles/popular_sites.h"
22 #include "components/suggestions/proto/suggestions.pb.h" 22 #include "components/suggestions/proto/suggestions.pb.h"
23 #include "components/suggestions/suggestions_service.h" 23 #include "components/suggestions/suggestions_service.h"
24 #include "url/gurl.h" 24 #include "url/gurl.h"
25 25
26 namespace gfx { 26 namespace gfx {
27 class Image; 27 class Image;
28 } 28 }
29 29
30 namespace history { 30 namespace history {
31 class TopSites; 31 class TopSites;
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
121 Suggestion(); 121 Suggestion();
122 ~Suggestion(); 122 ~Suggestion();
123 123
124 Suggestion(Suggestion&&); 124 Suggestion(Suggestion&&);
125 Suggestion& operator=(Suggestion&&); 125 Suggestion& operator=(Suggestion&&);
126 126
127 private: 127 private:
128 DISALLOW_COPY_AND_ASSIGN(Suggestion); 128 DISALLOW_COPY_AND_ASSIGN(Suggestion);
129 }; 129 };
130 130
131 MostVisitedSites(scoped_refptr<base::SequencedWorkerPool> blocking_pool, 131 MostVisitedSites(PrefService* prefs,
132 PrefService* prefs,
133 const TemplateURLService* template_url_service, 132 const TemplateURLService* template_url_service,
134 variations::VariationsService* variations_service, 133 variations::VariationsService* variations_service,
135 net::URLRequestContextGetter* download_context, 134 net::URLRequestContextGetter* download_context,
136 const base::FilePath& popular_sites_directory, 135 const base::FilePath& popular_sites_directory,
137 scoped_refptr<history::TopSites> top_sites, 136 scoped_refptr<history::TopSites> top_sites,
138 suggestions::SuggestionsService* suggestions, 137 suggestions::SuggestionsService* suggestions,
139 MostVisitedSitesSupervisor* supervisor); 138 MostVisitedSitesSupervisor* supervisor);
140 139
141 ~MostVisitedSites() override; 140 ~MostVisitedSites() override;
142 141
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
269 suggestions_subscription_; 268 suggestions_subscription_;
270 269
271 ScopedObserver<history::TopSites, history::TopSitesObserver> scoped_observer_; 270 ScopedObserver<history::TopSites, history::TopSitesObserver> scoped_observer_;
272 271
273 MostVisitedSource mv_source_; 272 MostVisitedSource mv_source_;
274 273
275 std::unique_ptr<PopularSites> popular_sites_; 274 std::unique_ptr<PopularSites> popular_sites_;
276 275
277 SuggestionsVector current_suggestions_; 276 SuggestionsVector current_suggestions_;
278 277
279 base::ThreadChecker thread_checker_;
280 scoped_refptr<base::SequencedWorkerPool> blocking_pool_;
281 scoped_refptr<base::TaskRunner> blocking_runner_;
282
283 // For callbacks may be run after destruction. 278 // For callbacks may be run after destruction.
284 base::WeakPtrFactory<MostVisitedSites> weak_ptr_factory_; 279 base::WeakPtrFactory<MostVisitedSites> weak_ptr_factory_;
285 280
286 DISALLOW_COPY_AND_ASSIGN(MostVisitedSites); 281 DISALLOW_COPY_AND_ASSIGN(MostVisitedSites);
287 }; 282 };
288 283
289 #endif // COMPONENTS_NTP_TILES_MOST_VISITED_SITES_H_ 284 #endif // CHROME_BROWSER_ANDROID_NTP_MOST_VISITED_SITES_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698