Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(20)

Side by Side Diff: chrome/browser/extensions/api/settings_private/prefs_util.cc

Issue 1372053002: Flesh out the location-page class to make it more general. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address feedback from Dan and Michael Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 "base/prefs/pref_service.h" 7 #include "base/prefs/pref_service.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/profiles/profile.h" 10 #include "chrome/browser/profiles/profile.h"
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 (*s_whitelist)["browser.clear_data.hosted_apps_data"] = 107 (*s_whitelist)["browser.clear_data.hosted_apps_data"] =
108 settings_private::PrefType::PREF_TYPE_BOOLEAN; 108 settings_private::PrefType::PREF_TYPE_BOOLEAN;
109 (*s_whitelist)["browser.clear_data.content_licenses"] = 109 (*s_whitelist)["browser.clear_data.content_licenses"] =
110 settings_private::PrefType::PREF_TYPE_BOOLEAN; 110 settings_private::PrefType::PREF_TYPE_BOOLEAN;
111 (*s_whitelist)["browser.clear_data.time_period"] = 111 (*s_whitelist)["browser.clear_data.time_period"] =
112 settings_private::PrefType::PREF_TYPE_NUMBER; 112 settings_private::PrefType::PREF_TYPE_NUMBER;
113 (*s_whitelist)["translate.enabled"] = 113 (*s_whitelist)["translate.enabled"] =
114 settings_private::PrefType::PREF_TYPE_BOOLEAN; 114 settings_private::PrefType::PREF_TYPE_BOOLEAN;
115 (*s_whitelist)["translate_blocked_languages"] = 115 (*s_whitelist)["translate_blocked_languages"] =
116 settings_private::PrefType::PREF_TYPE_LIST; 116 settings_private::PrefType::PREF_TYPE_LIST;
117 (*s_whitelist)["profile.default_content_setting_values.cookies"] =
118 settings_private::PrefType::PREF_TYPE_NUMBER;
119 (*s_whitelist)["profile.default_content_setting_values.fullscreen"] =
120 settings_private::PrefType::PREF_TYPE_NUMBER;
121 (*s_whitelist)["profile.default_content_setting_values.geolocation"] =
122 settings_private::PrefType::PREF_TYPE_NUMBER;
123 (*s_whitelist)["profile.default_content_setting_values.javascript"] =
124 settings_private::PrefType::PREF_TYPE_NUMBER;
125 (*s_whitelist)["profile.default_content_setting_values.media_stream_camera"] =
126 settings_private::PrefType::PREF_TYPE_NUMBER;
127 (*s_whitelist)["profile.default_content_setting_values.media_stream_mic"] =
128 settings_private::PrefType::PREF_TYPE_NUMBER;
129 (*s_whitelist)["profile.default_content_setting_values.notifications"] =
130 settings_private::PrefType::PREF_TYPE_NUMBER;
131 (*s_whitelist)["profile.default_content_setting_values.popups"] =
132 settings_private::PrefType::PREF_TYPE_NUMBER;
133 (*s_whitelist)["profile.content_settings.exceptions.cookies"] =
134 settings_private::PrefType::PREF_TYPE_DICTIONARY;
135 (*s_whitelist)["profile.content_settings.exceptions.fullscreen"] =
136 settings_private::PrefType::PREF_TYPE_DICTIONARY;
137 (*s_whitelist)["profile.content_settings.exceptions.geolocation"] =
138 settings_private::PrefType::PREF_TYPE_DICTIONARY;
139 (*s_whitelist)["profile.content_settings.exceptions.javascript"] =
140 settings_private::PrefType::PREF_TYPE_DICTIONARY;
141 (*s_whitelist)["profile.content_settings.exceptions.media_stream_camera"] =
142 settings_private::PrefType::PREF_TYPE_DICTIONARY;
143 (*s_whitelist)["profile.content_settings.exceptions.media_stream_mic"] =
144 settings_private::PrefType::PREF_TYPE_DICTIONARY;
145 (*s_whitelist)["profile.content_settings.exceptions.notifications"] =
146 settings_private::PrefType::PREF_TYPE_DICTIONARY;
147 (*s_whitelist)["profile.content_settings.exceptions.popups"] =
148 settings_private::PrefType::PREF_TYPE_DICTIONARY;
117 149
118 #if defined(OS_CHROMEOS) 150 #if defined(OS_CHROMEOS)
119 (*s_whitelist)["cros.accounts.allowBWSI"] = 151 (*s_whitelist)["cros.accounts.allowBWSI"] =
120 settings_private::PrefType::PREF_TYPE_BOOLEAN; 152 settings_private::PrefType::PREF_TYPE_BOOLEAN;
121 (*s_whitelist)["cros.accounts.supervisedUsersEnabled"] = 153 (*s_whitelist)["cros.accounts.supervisedUsersEnabled"] =
122 settings_private::PrefType::PREF_TYPE_BOOLEAN; 154 settings_private::PrefType::PREF_TYPE_BOOLEAN;
123 (*s_whitelist)["cros.accounts.showUserNamesOnSignIn"] = 155 (*s_whitelist)["cros.accounts.showUserNamesOnSignIn"] =
124 settings_private::PrefType::PREF_TYPE_BOOLEAN; 156 settings_private::PrefType::PREF_TYPE_BOOLEAN;
125 (*s_whitelist)["cros.accounts.allowGuest"] = 157 (*s_whitelist)["cros.accounts.allowGuest"] =
126 settings_private::PrefType::PREF_TYPE_BOOLEAN; 158 settings_private::PrefType::PREF_TYPE_BOOLEAN;
(...skipping 373 matching lines...) Expand 10 before | Expand all | Expand 10 after
500 532
501 bool PrefsUtil::IsCrosSetting(const std::string& pref_name) { 533 bool PrefsUtil::IsCrosSetting(const std::string& pref_name) {
502 #if defined(OS_CHROMEOS) 534 #if defined(OS_CHROMEOS)
503 return CrosSettings::Get()->IsCrosSettings(pref_name); 535 return CrosSettings::Get()->IsCrosSettings(pref_name);
504 #else 536 #else
505 return false; 537 return false;
506 #endif 538 #endif
507 } 539 }
508 540
509 } // namespace extensions 541 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698