| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/extensions/api/settings_private/prefs_util.h" | 5 #include "chrome/browser/extensions/api/settings_private/prefs_util.h" |
| 6 | 6 |
| 7 #include "build/build_config.h" | 7 #include "build/build_config.h" |
| 8 #include "chrome/browser/browser_process.h" | 8 #include "chrome/browser/browser_process.h" |
| 9 #include "chrome/browser/extensions/chrome_extension_function.h" | 9 #include "chrome/browser/extensions/chrome_extension_function.h" |
| 10 #include "chrome/browser/extensions/settings_api_helpers.h" | 10 #include "chrome/browser/extensions/settings_api_helpers.h" |
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 113 (*s_whitelist)[::prefs::kWebKitFixedFontFamily] = | 113 (*s_whitelist)[::prefs::kWebKitFixedFontFamily] = |
| 114 settings_private::PrefType::PREF_TYPE_STRING; | 114 settings_private::PrefType::PREF_TYPE_STRING; |
| 115 (*s_whitelist)[::prefs::kWebKitSansSerifFontFamily] = | 115 (*s_whitelist)[::prefs::kWebKitSansSerifFontFamily] = |
| 116 settings_private::PrefType::PREF_TYPE_STRING; | 116 settings_private::PrefType::PREF_TYPE_STRING; |
| 117 (*s_whitelist)[::prefs::kWebKitSerifFontFamily] = | 117 (*s_whitelist)[::prefs::kWebKitSerifFontFamily] = |
| 118 settings_private::PrefType::PREF_TYPE_STRING; | 118 settings_private::PrefType::PREF_TYPE_STRING; |
| 119 (*s_whitelist)[::prefs::kWebKitStandardFontFamily] = | 119 (*s_whitelist)[::prefs::kWebKitStandardFontFamily] = |
| 120 settings_private::PrefType::PREF_TYPE_STRING; | 120 settings_private::PrefType::PREF_TYPE_STRING; |
| 121 (*s_whitelist)[::prefs::kDefaultCharset] = | 121 (*s_whitelist)[::prefs::kDefaultCharset] = |
| 122 settings_private::PrefType::PREF_TYPE_STRING; | 122 settings_private::PrefType::PREF_TYPE_STRING; |
| 123 #if defined(OS_MACOSX) |
| 124 (*s_whitelist)[::prefs::kWebkitTabsToLinks] = |
| 125 settings_private::PrefType::PREF_TYPE_BOOLEAN; |
| 126 #endif |
| 123 | 127 |
| 124 // On startup. | 128 // On startup. |
| 125 (*s_whitelist)[::prefs::kRestoreOnStartup] = | 129 (*s_whitelist)[::prefs::kRestoreOnStartup] = |
| 126 settings_private::PrefType::PREF_TYPE_NUMBER; | 130 settings_private::PrefType::PREF_TYPE_NUMBER; |
| 127 (*s_whitelist)[::prefs::kURLsToRestoreOnStartup] = | 131 (*s_whitelist)[::prefs::kURLsToRestoreOnStartup] = |
| 128 settings_private::PrefType::PREF_TYPE_LIST; | 132 settings_private::PrefType::PREF_TYPE_LIST; |
| 129 | 133 |
| 130 // Downloads settings. | 134 // Downloads settings. |
| 131 (*s_whitelist)[::prefs::kDownloadDefaultDirectory] = | 135 (*s_whitelist)[::prefs::kDownloadDefaultDirectory] = |
| 132 settings_private::PrefType::PREF_TYPE_STRING; | 136 settings_private::PrefType::PREF_TYPE_STRING; |
| (...skipping 638 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 771 ExtensionPrefValueMapFactory::GetForBrowserContext(profile_) | 775 ExtensionPrefValueMapFactory::GetForBrowserContext(profile_) |
| 772 ->GetExtensionControllingPref(pref_object.key); | 776 ->GetExtensionControllingPref(pref_object.key); |
| 773 if (extension_id.empty()) | 777 if (extension_id.empty()) |
| 774 return nullptr; | 778 return nullptr; |
| 775 | 779 |
| 776 return ExtensionRegistry::Get(profile_)->GetExtensionById( | 780 return ExtensionRegistry::Get(profile_)->GetExtensionById( |
| 777 extension_id, ExtensionRegistry::ENABLED); | 781 extension_id, ExtensionRegistry::ENABLED); |
| 778 } | 782 } |
| 779 | 783 |
| 780 } // namespace extensions | 784 } // namespace extensions |
| OLD | NEW |