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

Side by Side Diff: chrome/browser/chromeos/preferences.cc

Issue 2467023004: Make the toggle touchscreen/touchpad shortcuts apply per-user (Closed)
Patch Set: Doing the migration right Created 4 years, 1 month 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
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/chromeos/preferences.h" 5 #include "chrome/browser/chromeos/preferences.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "ash/autoclick/autoclick_controller.h" 9 #include "ash/autoclick/autoclick_controller.h"
10 #include "ash/common/accessibility_types.h" 10 #include "ash/common/accessibility_types.h"
(...skipping 688 matching lines...) Expand 10 before | Expand all | Expand 10 after
699 } 699 }
700 } 700 }
701 } 701 }
702 702
703 if (pref_name == prefs::kUse24HourClock || 703 if (pref_name == prefs::kUse24HourClock ||
704 reason != REASON_ACTIVE_USER_CHANGED) { 704 reason != REASON_ACTIVE_USER_CHANGED) {
705 const bool value = prefs_->GetBoolean(prefs::kUse24HourClock); 705 const bool value = prefs_->GetBoolean(prefs::kUse24HourClock);
706 user_manager::known_user::SetBooleanPref(user_->GetAccountId(), 706 user_manager::known_user::SetBooleanPref(user_->GetAccountId(),
707 prefs::kUse24HourClock, value); 707 prefs::kUse24HourClock, value);
708 } 708 }
709
710 system::InputDeviceSettings::Get()
711 ->UpdateTouchDevicesStatusFromActiveProfilePrefs();
709 } 712 }
710 713
711 void Preferences::OnIsSyncingChanged() { 714 void Preferences::OnIsSyncingChanged() {
712 DVLOG(1) << "OnIsSyncingChanged"; 715 DVLOG(1) << "OnIsSyncingChanged";
713 ForceNaturalScrollDefault(); 716 ForceNaturalScrollDefault();
714 } 717 }
715 718
716 void Preferences::ForceNaturalScrollDefault() { 719 void Preferences::ForceNaturalScrollDefault() {
717 DVLOG(1) << "ForceNaturalScrollDefault"; 720 DVLOG(1) << "ForceNaturalScrollDefault";
718 if (base::CommandLine::ForCurrentProcess()->HasSwitch( 721 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
792 touch_hud_projection_enabled_.SetValue(enabled); 795 touch_hud_projection_enabled_.SetValue(enabled);
793 } 796 }
794 797
795 void Preferences::ActiveUserChanged(const user_manager::User* active_user) { 798 void Preferences::ActiveUserChanged(const user_manager::User* active_user) {
796 if (active_user != user_) 799 if (active_user != user_)
797 return; 800 return;
798 ApplyPreferences(REASON_ACTIVE_USER_CHANGED, ""); 801 ApplyPreferences(REASON_ACTIVE_USER_CHANGED, "");
799 } 802 }
800 803
801 } // namespace chromeos 804 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/chrome_browser_main_chromeos.cc ('k') | chrome/browser/chromeos/system/input_device_settings.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698