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

Side by Side Diff: chrome/browser/extensions/chrome_extensions_browser_client.cc

Issue 228343002: Cleanup webRequest/Internal API and permission registration. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressed comments. Created 6 years, 8 months 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/chrome_extensions_browser_client.h" 5 #include "chrome/browser/extensions/chrome_extensions_browser_client.h"
6 6
7 #include "apps/common/api/generated_api.h" 7 #include "apps/common/api/generated_api.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/version.h" 9 #include "base/version.h"
10 #include "chrome/browser/app_mode/app_mode_utils.h" 10 #include "chrome/browser/app_mode/app_mode_utils.h"
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after
210 ChromeExtensionsBrowserClient::GetExtensionSystemFactory() { 210 ChromeExtensionsBrowserClient::GetExtensionSystemFactory() {
211 return ExtensionSystemFactory::GetInstance(); 211 return ExtensionSystemFactory::GetInstance();
212 } 212 }
213 213
214 void ChromeExtensionsBrowserClient::RegisterExtensionFunctions( 214 void ChromeExtensionsBrowserClient::RegisterExtensionFunctions(
215 ExtensionFunctionRegistry* registry) const { 215 ExtensionFunctionRegistry* registry) const {
216 // TODO(rockot): Figure out if and why Android really needs to build 216 // TODO(rockot): Figure out if and why Android really needs to build
217 // ChromeExtensionsBrowserClient and refactor so this ifdef isn't necessary. 217 // ChromeExtensionsBrowserClient and refactor so this ifdef isn't necessary.
218 // See http://crbug.com/349436 218 // See http://crbug.com/349436
219 #if defined(ENABLE_EXTENSIONS) 219 #if defined(ENABLE_EXTENSIONS)
220 // WebRequest.
221 registry->RegisterFunction<WebRequestAddEventListener>();
222 registry->RegisterFunction<WebRequestEventHandled>();
223
224 // Preferences. 220 // Preferences.
225 registry->RegisterFunction<extensions::GetPreferenceFunction>(); 221 registry->RegisterFunction<extensions::GetPreferenceFunction>();
226 registry->RegisterFunction<extensions::SetPreferenceFunction>(); 222 registry->RegisterFunction<extensions::SetPreferenceFunction>();
227 registry->RegisterFunction<extensions::ClearPreferenceFunction>(); 223 registry->RegisterFunction<extensions::ClearPreferenceFunction>();
228 224
229 // Direct Preference Access for Component Extensions. 225 // Direct Preference Access for Component Extensions.
230 registry->RegisterFunction< 226 registry->RegisterFunction<
231 extensions::chromedirectsetting::GetDirectSettingFunction>(); 227 extensions::chromedirectsetting::GetDirectSettingFunction>();
232 registry->RegisterFunction< 228 registry->RegisterFunction<
233 extensions::chromedirectsetting::SetDirectSettingFunction>(); 229 extensions::chromedirectsetting::SetDirectSettingFunction>();
234 registry->RegisterFunction< 230 registry->RegisterFunction<
235 extensions::chromedirectsetting::ClearDirectSettingFunction>(); 231 extensions::chromedirectsetting::ClearDirectSettingFunction>();
236 232
237 // Generated APIs from lower-level modules. 233 // Generated APIs from lower-level modules.
238 extensions::core_api::GeneratedFunctionRegistry::RegisterAll(registry); 234 extensions::core_api::GeneratedFunctionRegistry::RegisterAll(registry);
239 apps::api::GeneratedFunctionRegistry::RegisterAll(registry); 235 apps::api::GeneratedFunctionRegistry::RegisterAll(registry);
240 236
241 // Generated APIs from Chrome. 237 // Generated APIs from Chrome.
242 extensions::api::GeneratedFunctionRegistry::RegisterAll(registry); 238 extensions::api::GeneratedFunctionRegistry::RegisterAll(registry);
243 #endif 239 #endif
244 } 240 }
245 241
246 } // namespace extensions 242 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/browser/extensions/api/web_request/web_request_api.cc ('k') | chrome/common/extensions/api/_api_features.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698