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

Unified Diff: chrome/browser/browser_main.cc

Issue 7791029: When the user navigates to the home page, make sure to set the RLZ string (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: When the user navigates to the home page, make sure to set the RLZ string Created 9 years, 4 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/instant/instant_loader.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/browser_main.cc
===================================================================
--- chrome/browser/browser_main.cc (revision 99286)
+++ chrome/browser/browser_main.cc (working copy)
@@ -44,6 +44,7 @@
#include "chrome/browser/first_run/first_run.h"
#include "chrome/browser/first_run/first_run_browser_process.h"
#include "chrome/browser/first_run/upgrade_util.h"
+#include "chrome/browser/google/google_url_tracker.h"
#include "chrome/browser/instant/instant_field_trial.h"
#include "chrome/browser/jankometer.h"
#include "chrome/browser/language_usage_metrics.h"
@@ -1880,11 +1881,23 @@
}
}
}
- // TODO(rogerta): For now, always passing false for google_homeapge_default
- // argument, so that functionality is disabled. A follow up CL will set it
- // correctly.
+
+ bool google_search_homepage = false;
+ PrefService* pref_service = profile->GetPrefs();
+ if (pref_service) {
+ std::string homepage = pref_service->GetString(prefs::kHomePage);
+ google_search_homepage =
+ homepage == GoogleURLTracker::kDefaultGoogleHomepage;
+ }
+
RLZTracker::InitRlzDelayed(is_first_run, master_prefs.ping_delay,
- google_search_default, false);
+ google_search_default, google_search_homepage);
+
+ // Prime the RLZ cache for the home page access point so that its avaiable
+ // for the startup page if needed (i.e., when the startup page is set to
+ // the home page).
+ RLZTracker::GetAccessPointRlz(rlz_lib::CHROME_HOME_PAGE, NULL);
+
#endif // GOOGLE_CHROME_BUILD
#endif // OS_WIN
« no previous file with comments | « no previous file | chrome/browser/instant/instant_loader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698