OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/service/service_process_prefs.h" | 5 #include "chrome/service/service_process_prefs.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/prefs/pref_filter.h" | |
10 #include "base/thread_task_runner_handle.h" | 9 #include "base/thread_task_runner_handle.h" |
11 #include "base/values.h" | 10 #include "base/values.h" |
| 11 #include "components/prefs/pref_filter.h" |
12 | 12 |
13 ServiceProcessPrefs::ServiceProcessPrefs( | 13 ServiceProcessPrefs::ServiceProcessPrefs( |
14 const base::FilePath& pref_filename, | 14 const base::FilePath& pref_filename, |
15 base::SequencedTaskRunner* task_runner) | 15 base::SequencedTaskRunner* task_runner) |
16 : prefs_(new JsonPrefStore(pref_filename, | 16 : prefs_(new JsonPrefStore(pref_filename, |
17 task_runner, | 17 task_runner, |
18 scoped_ptr<PrefFilter>())) { | 18 scoped_ptr<PrefFilter>())) { |
19 } | 19 } |
20 | 20 |
21 ServiceProcessPrefs::~ServiceProcessPrefs() {} | 21 ServiceProcessPrefs::~ServiceProcessPrefs() {} |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
98 void ServiceProcessPrefs::SetValue(const std::string& key, | 98 void ServiceProcessPrefs::SetValue(const std::string& key, |
99 scoped_ptr<base::Value> value) { | 99 scoped_ptr<base::Value> value) { |
100 prefs_->SetValue(key, std::move(value), | 100 prefs_->SetValue(key, std::move(value), |
101 WriteablePrefStore::DEFAULT_PREF_WRITE_FLAGS); | 101 WriteablePrefStore::DEFAULT_PREF_WRITE_FLAGS); |
102 } | 102 } |
103 | 103 |
104 void ServiceProcessPrefs::RemovePref(const std::string& key) { | 104 void ServiceProcessPrefs::RemovePref(const std::string& key) { |
105 prefs_->RemoveValue(key, WriteablePrefStore::DEFAULT_PREF_WRITE_FLAGS); | 105 prefs_->RemoveValue(key, WriteablePrefStore::DEFAULT_PREF_WRITE_FLAGS); |
106 } | 106 } |
107 | 107 |
OLD | NEW |