Chromium Code Reviews| Index: chrome/browser/chromeos/system/ash_system_tray_delegate.cc |
| diff --git a/chrome/browser/chromeos/system/ash_system_tray_delegate.cc b/chrome/browser/chromeos/system/ash_system_tray_delegate.cc |
| index e1f6c83fd0850202b6b6977f6b2b76c2d5424919..dc96359b5229ab441c81fb5fe3989464eab260a4 100644 |
| --- a/chrome/browser/chromeos/system/ash_system_tray_delegate.cc |
| +++ b/chrome/browser/chromeos/system/ash_system_tray_delegate.cc |
| @@ -873,6 +873,10 @@ class SystemTrayDelegate : public ash::SystemTrayDelegate, |
| base::Bind(&SystemTrayDelegate::UpdateShowLogoutButtonInTray, |
| base::Unretained(this))); |
| user_pref_registrar_->Add( |
| + prefs::kLogoutDialogDurationMs, |
| + base::Bind(&SystemTrayDelegate::UpdateLogoutDialogDuration, |
| + base::Unretained(this))); |
| + user_pref_registrar_->Add( |
| prefs::kLargeCursorEnabled, |
| base::Bind(&SystemTrayDelegate::OnAccessibilityModeChanged, |
| base::Unretained(this), |
| @@ -894,6 +898,7 @@ class SystemTrayDelegate : public ash::SystemTrayDelegate, |
| UpdateClockType(); |
| UpdateShowLogoutButtonInTray(); |
| + UpdateLogoutDialogDuration(); |
| UpdatePerformanceTracing(); |
| search_key_mapped_to_ = |
| profile->GetPrefs()->GetInteger(prefs::kLanguageRemapSearchKeyTo); |
| @@ -965,6 +970,13 @@ class SystemTrayDelegate : public ash::SystemTrayDelegate, |
| prefs::kShowLogoutButtonInTray)); |
| } |
| + void UpdateLogoutDialogDuration() { |
| + int duration_ms = user_pref_registrar_->prefs()->GetInteger( |
|
bartfab (slow)
2013/12/10 12:41:16
Nit: const.
binjin
2013/12/12 13:56:55
Done.
|
| + prefs::kLogoutDialogDurationMs); |
| + GetSystemTrayNotifier()->NotifyLogoutDialogDurationChanged( |
| + base::TimeDelta::FromMilliseconds(duration_ms)); |
| + } |
| + |
| void UpdateSessionStartTime() { |
| const PrefService* local_state = local_state_registrar_->prefs(); |
| if (local_state->HasPrefPath(prefs::kSessionStartTime)) { |