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

Side by Side Diff: chrome/browser/signin/signin_ui_util.cc

Issue 562603002: Move PageTransition from //content/public/common to //ui/base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 years, 3 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
« no previous file with comments | « chrome/browser/signin/signin_header_helper.cc ('k') | chrome/browser/ssl/ssl_browser_tests.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 #include "chrome/browser/signin/signin_ui_util.h" 5 #include "chrome/browser/signin/signin_ui_util.h"
6 6
7 #include "base/prefs/pref_service.h" 7 #include "base/prefs/pref_service.h"
8 #include "base/strings/sys_string_conversions.h" 8 #include "base/strings/sys_string_conversions.h"
9 #include "base/strings/utf_string_conversions.h" 9 #include "base/strings/utf_string_conversions.h"
10 #include "chrome/browser/profiles/profile.h" 10 #include "chrome/browser/profiles/profile.h"
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
164 if (profile->IsNewProfile() && switches::IsNewAvatarMenu()) { 164 if (profile->IsNewProfile() && switches::IsNewAvatarMenu()) {
165 profile->GetPrefs()->SetInteger( 165 profile->GetPrefs()->SetInteger(
166 prefs::kProfileAvatarTutorialShown, kUpgradeWelcomeTutorialShowMax + 1); 166 prefs::kProfileAvatarTutorialShown, kUpgradeWelcomeTutorialShowMax + 1);
167 } 167 }
168 } 168 }
169 169
170 void ShowSigninErrorLearnMorePage(Profile* profile) { 170 void ShowSigninErrorLearnMorePage(Profile* profile) {
171 static const char kSigninErrorLearnMoreUrl[] = 171 static const char kSigninErrorLearnMoreUrl[] =
172 "https://support.google.com/chrome/answer/1181420?"; 172 "https://support.google.com/chrome/answer/1181420?";
173 chrome::NavigateParams params( 173 chrome::NavigateParams params(
174 profile, GURL(kSigninErrorLearnMoreUrl), content::PAGE_TRANSITION_LINK); 174 profile, GURL(kSigninErrorLearnMoreUrl), ui::PAGE_TRANSITION_LINK);
175 params.disposition = NEW_FOREGROUND_TAB; 175 params.disposition = NEW_FOREGROUND_TAB;
176 chrome::Navigate(&params); 176 chrome::Navigate(&params);
177 } 177 }
178 178
179 std::string GetDisplayEmail(Profile* profile, const std::string& account_id) { 179 std::string GetDisplayEmail(Profile* profile, const std::string& account_id) {
180 AccountTrackerService* account_tracker = 180 AccountTrackerService* account_tracker =
181 AccountTrackerServiceFactory::GetForProfile(profile); 181 AccountTrackerServiceFactory::GetForProfile(profile);
182 std::string email = account_tracker->GetAccountInfo(account_id).email; 182 std::string email = account_tracker->GetAccountInfo(account_id).email;
183 if (email.empty()) { 183 if (email.empty()) {
184 DCHECK_EQ(AccountTrackerService::MIGRATION_NOT_STARTED, 184 DCHECK_EQ(AccountTrackerService::MIGRATION_NOT_STARTED,
185 account_tracker->GetMigrationState()); 185 account_tracker->GetMigrationState());
186 return account_id; 186 return account_id;
187 } 187 }
188 return email; 188 return email;
189 } 189 }
190 190
191 } // namespace signin_ui_util 191 } // namespace signin_ui_util
OLDNEW
« no previous file with comments | « chrome/browser/signin/signin_header_helper.cc ('k') | chrome/browser/ssl/ssl_browser_tests.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698