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

Side by Side Diff: chrome/browser/chromeos/settings/device_settings_provider.h

Issue 11975009: Prevent a DCHECK when starting a chromeos=1 build with --stub-cros-settings. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: share setting names list Created 7 years, 11 months 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/chromeos/settings/device_settings_provider.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #ifndef CHROME_BROWSER_CHROMEOS_SETTINGS_DEVICE_SETTINGS_PROVIDER_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_SETTINGS_DEVICE_SETTINGS_PROVIDER_H_
6 #define CHROME_BROWSER_CHROMEOS_SETTINGS_DEVICE_SETTINGS_PROVIDER_H_ 6 #define CHROME_BROWSER_CHROMEOS_SETTINGS_DEVICE_SETTINGS_PROVIDER_H_
7 7
8 #include <deque> 8 #include <deque>
9 #include <string> 9 #include <string>
10 #include <utility> 10 #include <utility>
(...skipping 19 matching lines...) Expand all
30 namespace chromeos { 30 namespace chromeos {
31 31
32 // CrosSettingsProvider implementation that works with device settings. 32 // CrosSettingsProvider implementation that works with device settings.
33 class DeviceSettingsProvider : public CrosSettingsProvider, 33 class DeviceSettingsProvider : public CrosSettingsProvider,
34 public DeviceSettingsService::Observer { 34 public DeviceSettingsService::Observer {
35 public: 35 public:
36 DeviceSettingsProvider(const NotifyObserversCallback& notify_cb, 36 DeviceSettingsProvider(const NotifyObserversCallback& notify_cb,
37 DeviceSettingsService* device_settings_service); 37 DeviceSettingsService* device_settings_service);
38 virtual ~DeviceSettingsProvider(); 38 virtual ~DeviceSettingsProvider();
39 39
40 // These pointers range over the setting names known to this provider.
41 static const char** kKnownSettingsBegin;
42 static const char** kKnownSettingsEnd;
Mattias Nissler (ping if slow) 2013/01/16 14:48:36 thinking about it, can't we just make this static
Joao da Silva 2013/01/16 15:10:08 Uh, of course. *main brain turn on* Done.
43
40 // CrosSettingsProvider implementation. 44 // CrosSettingsProvider implementation.
41 virtual const base::Value* Get(const std::string& path) const OVERRIDE; 45 virtual const base::Value* Get(const std::string& path) const OVERRIDE;
42 virtual TrustedStatus PrepareTrustedValues( 46 virtual TrustedStatus PrepareTrustedValues(
43 const base::Closure& callback) OVERRIDE; 47 const base::Closure& callback) OVERRIDE;
44 virtual bool HandlesSetting(const std::string& path) const OVERRIDE; 48 virtual bool HandlesSetting(const std::string& path) const OVERRIDE;
45 49
46 private: 50 private:
47 // CrosSettingsProvider implementation: 51 // CrosSettingsProvider implementation:
48 virtual void DoSet(const std::string& path, 52 virtual void DoSet(const std::string& path,
49 const base::Value& value) OVERRIDE; 53 const base::Value& value) OVERRIDE;
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
157 InitializationTestUnowned); 161 InitializationTestUnowned);
158 FRIEND_TEST_ALL_PREFIXES(DeviceSettingsProviderTest, 162 FRIEND_TEST_ALL_PREFIXES(DeviceSettingsProviderTest,
159 PolicyFailedPermanentlyNotification); 163 PolicyFailedPermanentlyNotification);
160 FRIEND_TEST_ALL_PREFIXES(DeviceSettingsProviderTest, PolicyLoadNotification); 164 FRIEND_TEST_ALL_PREFIXES(DeviceSettingsProviderTest, PolicyLoadNotification);
161 DISALLOW_COPY_AND_ASSIGN(DeviceSettingsProvider); 165 DISALLOW_COPY_AND_ASSIGN(DeviceSettingsProvider);
162 }; 166 };
163 167
164 } // namespace chromeos 168 } // namespace chromeos
165 169
166 #endif // CHROME_BROWSER_CHROMEOS_SETTINGS_DEVICE_SETTINGS_PROVIDER_H_ 170 #endif // CHROME_BROWSER_CHROMEOS_SETTINGS_DEVICE_SETTINGS_PROVIDER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/chromeos/settings/device_settings_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698