| 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 315 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 326 (*s_whitelist)[::prefs::kImportBookmarks] = | 326 (*s_whitelist)[::prefs::kImportBookmarks] = |
| 327 settings_private::PrefType::PREF_TYPE_BOOLEAN; | 327 settings_private::PrefType::PREF_TYPE_BOOLEAN; |
| 328 (*s_whitelist)[::prefs::kImportHistory] = | 328 (*s_whitelist)[::prefs::kImportHistory] = |
| 329 settings_private::PrefType::PREF_TYPE_BOOLEAN; | 329 settings_private::PrefType::PREF_TYPE_BOOLEAN; |
| 330 (*s_whitelist)[::prefs::kImportSavedPasswords] = | 330 (*s_whitelist)[::prefs::kImportSavedPasswords] = |
| 331 settings_private::PrefType::PREF_TYPE_BOOLEAN; | 331 settings_private::PrefType::PREF_TYPE_BOOLEAN; |
| 332 (*s_whitelist)[::prefs::kImportSearchEngine] = | 332 (*s_whitelist)[::prefs::kImportSearchEngine] = |
| 333 settings_private::PrefType::PREF_TYPE_BOOLEAN; | 333 settings_private::PrefType::PREF_TYPE_BOOLEAN; |
| 334 #endif | 334 #endif |
| 335 | 335 |
| 336 // Search settings. |
| 337 (*s_whitelist)[::prefs::kHotwordSearchEnabled] = |
| 338 settings_private::PrefType::PREF_TYPE_BOOLEAN; |
| 339 (*s_whitelist)[::prefs::kHotwordAlwaysOnSearchEnabled] = |
| 340 settings_private::PrefType::PREF_TYPE_BOOLEAN; |
| 341 |
| 336 // Proxy settings. | 342 // Proxy settings. |
| 337 (*s_whitelist)[proxy_config::prefs::kProxy] = | 343 (*s_whitelist)[proxy_config::prefs::kProxy] = |
| 338 settings_private::PrefType::PREF_TYPE_DICTIONARY; | 344 settings_private::PrefType::PREF_TYPE_DICTIONARY; |
| 339 | 345 |
| 340 #if defined(GOOGLE_CHROME_BUILD) | 346 #if defined(GOOGLE_CHROME_BUILD) |
| 341 (*s_whitelist)[::prefs::kMediaRouterEnableCloudServices] = | 347 (*s_whitelist)[::prefs::kMediaRouterEnableCloudServices] = |
| 342 settings_private::PrefType::PREF_TYPE_BOOLEAN; | 348 settings_private::PrefType::PREF_TYPE_BOOLEAN; |
| 343 #endif // defined(GOOGLE_CHROME_BUILD) | 349 #endif // defined(GOOGLE_CHROME_BUILD) |
| 344 | 350 |
| 345 return *s_whitelist; | 351 return *s_whitelist; |
| (...skipping 369 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 715 if (pref_object.key == ::prefs::kDefaultSearchProviderEnabled) | 721 if (pref_object.key == ::prefs::kDefaultSearchProviderEnabled) |
| 716 return GetExtensionOverridingSearchEngine(profile_); | 722 return GetExtensionOverridingSearchEngine(profile_); |
| 717 | 723 |
| 718 if (pref_object.key == proxy_config::prefs::kProxy) | 724 if (pref_object.key == proxy_config::prefs::kProxy) |
| 719 return GetExtensionOverridingProxy(profile_); | 725 return GetExtensionOverridingProxy(profile_); |
| 720 | 726 |
| 721 return nullptr; | 727 return nullptr; |
| 722 } | 728 } |
| 723 | 729 |
| 724 } // namespace extensions | 730 } // namespace extensions |
| OLD | NEW |