| OLD | NEW |
| 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 #ifndef CHROME_BROWSER_CHROMEOS_PREFERENCES_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_PREFERENCES_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_PREFERENCES_H_ | 6 #define CHROME_BROWSER_CHROMEOS_PREFERENCES_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | |
| 10 | 9 |
| 11 #include "ash/shell_observer.h" | 10 #include "ash/shell_observer.h" |
| 12 #include "base/compiler_specific.h" | 11 #include "base/compiler_specific.h" |
| 12 #include "base/memory/weak_ptr.h" |
| 13 #include "base/prefs/pref_member.h" | 13 #include "base/prefs/pref_member.h" |
| 14 #include "chrome/browser/chromeos/language_preferences.h" | 14 #include "chrome/browser/chromeos/language_preferences.h" |
| 15 #include "chrome/browser/prefs/pref_service_syncable_observer.h" | 15 #include "chrome/browser/prefs/pref_service_syncable_observer.h" |
| 16 #include "chromeos/ime/input_method_manager.h" | 16 #include "chromeos/ime/input_method_manager.h" |
| 17 #include "components/user_manager/user_manager.h" | 17 #include "components/user_manager/user_manager.h" |
| 18 | 18 |
| 19 class PrefRegistrySimple; | 19 class PrefRegistrySimple; |
| 20 class PrefService; | 20 class PrefService; |
| 21 class PrefServiceSyncable; | 21 class PrefServiceSyncable; |
| 22 | 22 |
| 23 class TracingManager; | 23 class TracingManager; |
| 24 | 24 |
| 25 namespace user_prefs { | 25 namespace user_prefs { |
| 26 class PrefRegistrySyncable; | 26 class PrefRegistrySyncable; |
| 27 } | 27 } |
| 28 | 28 |
| 29 namespace chromeos { | 29 namespace chromeos { |
| 30 | 30 |
| 31 class User; | 31 class User; |
| 32 | 32 |
| 33 namespace { |
| 34 class InputMethodSyncer; |
| 35 } |
| 36 |
| 33 namespace input_method { | 37 namespace input_method { |
| 34 class InputMethodManager; | 38 class InputMethodManager; |
| 35 } | 39 } |
| 36 | 40 |
| 37 // The Preferences class handles Chrome OS preferences. When the class | 41 // The Preferences class handles Chrome OS preferences. When the class |
| 38 // is first initialized, it will initialize the OS settings to what's stored in | 42 // is first initialized, it will initialize the OS settings to what's stored in |
| 39 // the preferences. These include touchpad settings, etc. | 43 // the preferences. These include touchpad settings, etc. |
| 40 // When the preferences change, we change the settings to reflect the new value. | 44 // When the preferences change, we change the settings to reflect the new value. |
| 41 class Preferences : public PrefServiceSyncableObserver, | 45 class Preferences : public PrefServiceSyncableObserver, |
| 42 public ash::ShellObserver, | 46 public ash::ShellObserver, |
| (...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 142 | 146 |
| 143 // User owning these preferences. | 147 // User owning these preferences. |
| 144 const user_manager::User* user_; | 148 const user_manager::User* user_; |
| 145 | 149 |
| 146 // Whether user is a primary user. | 150 // Whether user is a primary user. |
| 147 bool user_is_primary_; | 151 bool user_is_primary_; |
| 148 | 152 |
| 149 // Input Methods state for this user. | 153 // Input Methods state for this user. |
| 150 scoped_refptr<input_method::InputMethodManager::State> ime_state_; | 154 scoped_refptr<input_method::InputMethodManager::State> ime_state_; |
| 151 | 155 |
| 156 scoped_ptr<InputMethodSyncer> input_method_syncer_; |
| 157 |
| 152 DISALLOW_COPY_AND_ASSIGN(Preferences); | 158 DISALLOW_COPY_AND_ASSIGN(Preferences); |
| 153 }; | 159 }; |
| 154 | 160 |
| 155 } // namespace chromeos | 161 } // namespace chromeos |
| 156 | 162 |
| 157 #endif // CHROME_BROWSER_CHROMEOS_PREFERENCES_H_ | 163 #endif // CHROME_BROWSER_CHROMEOS_PREFERENCES_H_ |
| OLD | NEW |