| Index: chrome/browser/ui/ash/chrome_shell_delegate_chromeos.cc
|
| diff --git a/chrome/browser/ui/ash/chrome_shell_delegate_chromeos.cc b/chrome/browser/ui/ash/chrome_shell_delegate_chromeos.cc
|
| index 09becbbe96ac98fbd54706f64fe5ee2d0824b680..7c8209e8c7ed3fab0593a3331829a13a7f70f40a 100644
|
| --- a/chrome/browser/ui/ash/chrome_shell_delegate_chromeos.cc
|
| +++ b/chrome/browser/ui/ash/chrome_shell_delegate_chromeos.cc
|
| @@ -234,6 +234,35 @@ void ChromeShellDelegate::HandleMediaPrevTrack() {
|
| media_player_event_router()->NotifyPrevTrack();
|
| }
|
|
|
| +bool ChromeShellDelegate::IsTouchHudProjectionEnabled() const {
|
| + if (!ProfileManager::IsGetDefaultProfileAllowed())
|
| + return false;
|
| +
|
| + Profile* profile = ProfileManager::GetDefaultProfile();
|
| + if (!profile)
|
| + return false;
|
| +
|
| + PrefService* pref_service = profile->GetPrefs();
|
| + return pref_service &&
|
| + pref_service->GetBoolean(prefs::kTouchHudProjectionEnabled);
|
| +}
|
| +
|
| +void ChromeShellDelegate::ToggleTouchHudProjection() {
|
| + if (!ProfileManager::IsGetDefaultProfileAllowed())
|
| + return;
|
| +
|
| + Profile* profile = ProfileManager::GetDefaultProfile();
|
| + if (!profile)
|
| + return;
|
| +
|
| + PrefService* pref_service = profile->GetPrefs();
|
| + if (!pref_service)
|
| + return;
|
| +
|
| + bool enabled = pref_service->GetBoolean(prefs::kTouchHudProjectionEnabled);
|
| + pref_service->SetBoolean(prefs::kTouchHudProjectionEnabled, !enabled);
|
| +}
|
| +
|
| void ChromeShellDelegate::Observe(int type,
|
| const content::NotificationSource& source,
|
| const content::NotificationDetails& details) {
|
|
|