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

Side by Side Diff: chrome/browser/chromeos/settings/cros_settings.cc

Issue 1172183002: Move StartsWith[ASCII] to base namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@string_util3
Patch Set: merger Created 5 years, 6 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
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/settings/cros_settings.h" 5 #include "chrome/browser/chromeos/settings/cros_settings.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/stl_util.h" 10 #include "base/stl_util.h"
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 // System settings are not mocked currently. 79 // System settings are not mocked currently.
80 AddSettingsProvider(new SystemSettingsProvider(notify_cb)); 80 AddSettingsProvider(new SystemSettingsProvider(notify_cb));
81 } 81 }
82 82
83 CrosSettings::~CrosSettings() { 83 CrosSettings::~CrosSettings() {
84 STLDeleteElements(&providers_); 84 STLDeleteElements(&providers_);
85 STLDeleteValues(&settings_observers_); 85 STLDeleteValues(&settings_observers_);
86 } 86 }
87 87
88 bool CrosSettings::IsCrosSettings(const std::string& path) { 88 bool CrosSettings::IsCrosSettings(const std::string& path) {
89 return StartsWithASCII(path, kCrosSettingsPrefix, true); 89 return base::StartsWithASCII(path, kCrosSettingsPrefix, true);
90 } 90 }
91 91
92 void CrosSettings::Set(const std::string& path, const base::Value& in_value) { 92 void CrosSettings::Set(const std::string& path, const base::Value& in_value) {
93 DCHECK(CalledOnValidThread()); 93 DCHECK(CalledOnValidThread());
94 CrosSettingsProvider* provider; 94 CrosSettingsProvider* provider;
95 provider = GetProvider(path); 95 provider = GetProvider(path);
96 if (provider) 96 if (provider)
97 provider->Set(path, in_value); 97 provider->Set(path, in_value);
98 } 98 }
99 99
(...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after
340 340
341 ScopedTestCrosSettings::ScopedTestCrosSettings() { 341 ScopedTestCrosSettings::ScopedTestCrosSettings() {
342 CrosSettings::Initialize(); 342 CrosSettings::Initialize();
343 } 343 }
344 344
345 ScopedTestCrosSettings::~ScopedTestCrosSettings() { 345 ScopedTestCrosSettings::~ScopedTestCrosSettings() {
346 CrosSettings::Shutdown(); 346 CrosSettings::Shutdown();
347 } 347 }
348 348
349 } // namespace chromeos 349 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/proxy_cros_settings_parser.cc ('k') | chrome/browser/chromeos/system_logs/touch_log_source_ozone.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698