OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_PREF_STORE_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_PREF_STORE_H_ |
| 7 #pragma once |
| 8 |
| 9 #include "chrome/browser/prefs/value_map_pref_store.h" |
| 10 |
| 11 // A PrefStore implementation that holds preferences set by extensions. |
| 12 class ExtensionPrefStore : public ValueMapPrefStore { |
| 13 public: |
| 14 ExtensionPrefStore(); |
| 15 virtual ~ExtensionPrefStore() {} |
| 16 |
| 17 // Set an extension preference |value| for |key|. Takes ownership of |value|. |
| 18 void SetExtensionPref(const std::string& key, Value* value); |
| 19 |
| 20 // Remove the extension preference value for |key|. |
| 21 void RemoveExtensionPref(const std::string& key); |
| 22 |
| 23 // Tell the store it's now fully initialized. |
| 24 void OnInitializationCompleted(); |
| 25 |
| 26 private: |
| 27 // PrefStore overrides: |
| 28 virtual bool IsInitializationComplete() const; |
| 29 |
| 30 bool initialization_complete_; |
| 31 |
| 32 DISALLOW_COPY_AND_ASSIGN(ExtensionPrefStore); |
| 33 }; |
| 34 |
| 35 |
| 36 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_PREF_STORE_H_ |
OLD | NEW |