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

Unified Diff: chrome/browser/ui/browser.cc

Issue 8343052: Sync Promo: Tweak first tabs (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/browser.cc
diff --git a/chrome/browser/ui/browser.cc b/chrome/browser/ui/browser.cc
index 4023c19829043fc3e1ed8f15ab2028fcefc22cc7..f183d9b6fc205f4bc3cd89a2e15abd882dc9b1e6 100644
--- a/chrome/browser/ui/browser.cc
+++ b/chrome/browser/ui/browser.cc
@@ -2952,6 +2952,11 @@ void Browser::UpdateUIForNavigationInTab(TabContentsWrapper* contents,
}
GURL Browser::GetHomePage() const {
+ return GetHomePageForProfile(profile_);
+}
+
+// static
+GURL Browser::GetHomePageForProfile(Profile* profile) {
sky 2011/10/28 16:05:59 I don't think this method makes much sense on Brow
sail 2011/10/28 17:50:57 Done.
// --homepage overrides any preferences.
const CommandLine& command_line = *CommandLine::ForCurrentProcess();
if (command_line.HasSwitch(switches::kHomePage)) {
@@ -2968,10 +2973,10 @@ GURL Browser::GetHomePage() const {
return home_page;
}
- if (profile_->GetPrefs()->GetBoolean(prefs::kHomePageIsNewTabPage))
+ if (profile->GetPrefs()->GetBoolean(prefs::kHomePageIsNewTabPage))
return GURL(chrome::kChromeUINewTabURL);
GURL home_page(URLFixerUpper::FixupURL(
- profile_->GetPrefs()->GetString(prefs::kHomePage),
+ profile->GetPrefs()->GetString(prefs::kHomePage),
std::string()));
if (!home_page.is_valid())
return GURL(chrome::kChromeUINewTabURL);

Powered by Google App Engine
This is Rietveld 408576698