Index: chrome/browser/ui/ash/launcher/chrome_launcher_controller_per_app.cc |
diff --git a/chrome/browser/ui/ash/launcher/chrome_launcher_controller_per_app.cc b/chrome/browser/ui/ash/launcher/chrome_launcher_controller_per_app.cc |
index 557b26d7819e6115eac26685b0647bac4d53f660..a465a1681d55eeb07852ef4b3a9295dededb872e 100644 |
--- a/chrome/browser/ui/ash/launcher/chrome_launcher_controller_per_app.cc |
+++ b/chrome/browser/ui/ash/launcher/chrome_launcher_controller_per_app.cc |
@@ -19,7 +19,7 @@ |
#include "chrome/browser/extensions/extension_system.h" |
#include "chrome/browser/favicon/favicon_tab_helper.h" |
#include "chrome/browser/prefs/incognito_mode_prefs.h" |
-#include "chrome/browser/prefs/pref_service.h" |
+#include "chrome/browser/prefs/pref_service_syncable.h" |
#include "chrome/browser/prefs/scoped_user_pref_update.h" |
#include "chrome/browser/profiles/profile.h" |
#include "chrome/browser/profiles/profile_manager.h" |
@@ -220,7 +220,7 @@ ChromeLauncherControllerPerApp::~ChromeLauncherControllerPerApp() { |
if (app_sync_ui_state_) |
app_sync_ui_state_->RemoveObserver(this); |
- profile_->GetPrefs()->RemoveObserver(this); |
+ PrefServiceSyncable::FromProfile(profile_)->RemoveObserver(this); |
Mattias Nissler (ping if slow)
2013/02/06 17:53:33
Oh, this is the OnIsSyncingChanged stuff. I'll hav
Jói
2013/02/07 14:52:32
OK.
Mattias Nissler (ping if slow)
2013/02/08 14:49:18
FWIW, I've looked into this some more. I've found
|
} |
void ChromeLauncherControllerPerApp::Init() { |
@@ -230,7 +230,7 @@ void ChromeLauncherControllerPerApp::Init() { |
if (ash::Shell::HasInstance()) { |
SetShelfAutoHideBehaviorFromPrefs(); |
SetShelfAlignmentFromPrefs(); |
- PrefServiceSyncable* prefs = profile_->GetPrefs(); |
+ PrefServiceSyncable* prefs = PrefServiceSyncable::FromProfile(profile_); |
if (!prefs->FindPreference(prefs::kShelfAlignmentLocal)->HasUserSetting() || |
!prefs->FindPreference(prefs::kShelfAutoHideBehaviorLocal)-> |
HasUserSetting()) { |
@@ -937,10 +937,11 @@ void ChromeLauncherControllerPerApp::OnShelfAlignmentChanged( |
} |
void ChromeLauncherControllerPerApp::OnIsSyncingChanged() { |
- MaybePropagatePrefToLocal(profile_->GetPrefs(), |
+ PrefServiceSyncable* prefs = PrefServiceSyncable::FromProfile(profile_); |
+ MaybePropagatePrefToLocal(prefs, |
prefs::kShelfAlignmentLocal, |
prefs::kShelfAlignment); |
- MaybePropagatePrefToLocal(profile_->GetPrefs(), |
+ MaybePropagatePrefToLocal(prefs, |
prefs::kShelfAutoHideBehaviorLocal, |
prefs::kShelfAutoHideBehavior); |
} |