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

Side by Side Diff: chrome/browser/profiles/profile_impl.cc

Issue 144983002: Fixed chrome://settings/accounts availability for MP. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/profiles/profile_impl.h" 5 #include "chrome/browser/profiles/profile_impl.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 1180 matching lines...) Expand 10 before | Expand all | Expand 10 after
1191 case APP_LOCALE_CHANGED_VIA_UNKNOWN: 1191 case APP_LOCALE_CHANGED_VIA_UNKNOWN:
1192 default: { 1192 default: {
1193 NOTREACHED(); 1193 NOTREACHED();
1194 break; 1194 break;
1195 } 1195 }
1196 } 1196 }
1197 if (do_update_pref) 1197 if (do_update_pref)
1198 GetPrefs()->SetString(prefs::kApplicationLocale, new_locale); 1198 GetPrefs()->SetString(prefs::kApplicationLocale, new_locale);
1199 local_state->SetString(prefs::kApplicationLocale, new_locale); 1199 local_state->SetString(prefs::kApplicationLocale, new_locale);
1200 1200
1201 if (chromeos::UserManager::Get()->IsCurrentUserOwner()) 1201 if (chromeos::ProfileHelper::IsProfileOwner(this))
1202 local_state->SetString(prefs::kOwnerLocale, new_locale); 1202 local_state->SetString(prefs::kOwnerLocale, new_locale);
1203 } 1203 }
1204 1204
1205 void ProfileImpl::OnLogin() { 1205 void ProfileImpl::OnLogin() {
1206 if (locale_change_guard_ == NULL) 1206 if (locale_change_guard_ == NULL)
1207 locale_change_guard_.reset(new chromeos::LocaleChangeGuard(this)); 1207 locale_change_guard_.reset(new chromeos::LocaleChangeGuard(this));
1208 locale_change_guard_->OnLogin(); 1208 locale_change_guard_->OnLogin();
1209 } 1209 }
1210 1210
1211 void ProfileImpl::InitChromeOSPreferences() { 1211 void ProfileImpl::InitChromeOSPreferences() {
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after
1324 PrefProxyConfigTracker* ProfileImpl::CreateProxyConfigTracker() { 1324 PrefProxyConfigTracker* ProfileImpl::CreateProxyConfigTracker() {
1325 #if defined(OS_CHROMEOS) 1325 #if defined(OS_CHROMEOS)
1326 if (chromeos::ProfileHelper::IsSigninProfile(this)) { 1326 if (chromeos::ProfileHelper::IsSigninProfile(this)) {
1327 return ProxyServiceFactory::CreatePrefProxyConfigTrackerOfLocalState( 1327 return ProxyServiceFactory::CreatePrefProxyConfigTrackerOfLocalState(
1328 g_browser_process->local_state()); 1328 g_browser_process->local_state());
1329 } 1329 }
1330 #endif // defined(OS_CHROMEOS) 1330 #endif // defined(OS_CHROMEOS)
1331 return ProxyServiceFactory::CreatePrefProxyConfigTrackerOfProfile( 1331 return ProxyServiceFactory::CreatePrefProxyConfigTrackerOfProfile(
1332 GetPrefs(), g_browser_process->local_state()); 1332 GetPrefs(), g_browser_process->local_state());
1333 } 1333 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698