| 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_EXTENSIONS_EXTENSION_PREFS_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 508 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 519 const base::DictionaryValue* GetExtensionPref(const std::string& id) const; | 519 const base::DictionaryValue* GetExtensionPref(const std::string& id) const; |
| 520 | 520 |
| 521 // Loads the preferences controlled by the specified extension from their | 521 // Loads the preferences controlled by the specified extension from their |
| 522 // dictionary and sets them in the |pref_value_map_|. | 522 // dictionary and sets them in the |pref_value_map_|. |
| 523 void LoadExtensionControlledPrefs(const std::string& id, | 523 void LoadExtensionControlledPrefs(const std::string& id, |
| 524 ExtensionPrefsScope scope); | 524 ExtensionPrefsScope scope); |
| 525 | 525 |
| 526 // Checks if kPrefBlacklist is set to true in the DictionaryValue. | 526 // Checks if kPrefBlacklist is set to true in the DictionaryValue. |
| 527 // Return false if the value is false or kPrefBlacklist does not exist. | 527 // Return false if the value is false or kPrefBlacklist does not exist. |
| 528 // This is used to decide if an extension is blacklisted. | 528 // This is used to decide if an extension is blacklisted. |
| 529 static bool IsBlacklistBitSet(base::DictionaryValue* ext); | 529 static bool IsBlacklistBitSet(const base::DictionaryValue* ext); |
| 530 | 530 |
| 531 // Fix missing preference entries in the extensions that are were introduced | 531 // Fix missing preference entries in the extensions that are were introduced |
| 532 // in a later Chrome version. | 532 // in a later Chrome version. |
| 533 void FixMissingPrefs(const ExtensionIdSet& extension_ids); | 533 void FixMissingPrefs(const ExtensionIdSet& extension_ids); |
| 534 | 534 |
| 535 // Installs the persistent extension preferences into |prefs_|'s extension | 535 // Installs the persistent extension preferences into |prefs_|'s extension |
| 536 // pref store. Does nothing if |extensions_disabled| is true. | 536 // pref store. Does nothing if |extensions_disabled| is true. |
| 537 void InitPrefStore(bool extensions_disabled); | 537 void InitPrefStore(bool extensions_disabled); |
| 538 | 538 |
| 539 // Migrates the permissions data in the pref store. | 539 // Migrates the permissions data in the pref store. |
| (...skipping 18 matching lines...) Expand all Loading... |
| 558 scoped_ptr<ExtensionSorting> extension_sorting_; | 558 scoped_ptr<ExtensionSorting> extension_sorting_; |
| 559 | 559 |
| 560 scoped_refptr<ContentSettingsStore> content_settings_store_; | 560 scoped_refptr<ContentSettingsStore> content_settings_store_; |
| 561 | 561 |
| 562 DISALLOW_COPY_AND_ASSIGN(ExtensionPrefs); | 562 DISALLOW_COPY_AND_ASSIGN(ExtensionPrefs); |
| 563 }; | 563 }; |
| 564 | 564 |
| 565 } // namespace extensions | 565 } // namespace extensions |
| 566 | 566 |
| 567 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ | 567 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_PREFS_H_ |
| OLD | NEW |