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

Unified Diff: chrome/browser/android/ntp/most_visited_sites.cc

Issue 1919043005: Remove Profile dependency from PopularSites. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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
« no previous file with comments | « no previous file | chrome/browser/android/ntp/popular_sites.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/android/ntp/most_visited_sites.cc
diff --git a/chrome/browser/android/ntp/most_visited_sites.cc b/chrome/browser/android/ntp/most_visited_sites.cc
index 7b1de89be00a118b452baa49d13e27ffceee53a4..3f5e907abb813f43f886489faf6f2e35b343b3d2 100644
--- a/chrome/browser/android/ntp/most_visited_sites.cc
+++ b/chrome/browser/android/ntp/most_visited_sites.cc
@@ -19,6 +19,7 @@
#include "chrome/browser/history/top_sites_factory.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/search/suggestions/suggestions_service_factory.h"
+#include "chrome/browser/search_engines/template_url_service_factory.h"
#include "chrome/browser/supervised_user/supervised_user_service.h"
#include "chrome/browser/supervised_user/supervised_user_service_factory.h"
#include "chrome/browser/supervised_user/supervised_user_url_filter.h"
@@ -203,7 +204,9 @@ void MostVisitedSites::SetMostVisitedURLsObserver(
if (ShouldShowPopularSites() &&
NeedPopularSites(profile_->GetPrefs(), num_sites_)) {
popular_sites_.reset(new PopularSites(
- profile_,
+ profile_->GetPrefs(),
+ TemplateURLServiceFactory::GetForProfile(profile_),
+ profile_->GetRequestContext(),
GetPopularSitesCountry(),
GetPopularSitesVersion(),
false,
« no previous file with comments | « no previous file | chrome/browser/android/ntp/popular_sites.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698