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

Side by Side Diff: extensions/common/extension_api.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 "extensions/common/extension_api.h" 5 #include "extensions/common/extension_api.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after
246 RegisterSchemaResource("pageAction", IDR_EXTENSION_API_JSON_PAGEACTION); 246 RegisterSchemaResource("pageAction", IDR_EXTENSION_API_JSON_PAGEACTION);
247 RegisterSchemaResource("pageActions", IDR_EXTENSION_API_JSON_PAGEACTIONS); 247 RegisterSchemaResource("pageActions", IDR_EXTENSION_API_JSON_PAGEACTIONS);
248 RegisterSchemaResource("privacy", IDR_EXTENSION_API_JSON_PRIVACY); 248 RegisterSchemaResource("privacy", IDR_EXTENSION_API_JSON_PRIVACY);
249 RegisterSchemaResource("processes", IDR_EXTENSION_API_JSON_PROCESSES); 249 RegisterSchemaResource("processes", IDR_EXTENSION_API_JSON_PROCESSES);
250 RegisterSchemaResource("proxy", IDR_EXTENSION_API_JSON_PROXY); 250 RegisterSchemaResource("proxy", IDR_EXTENSION_API_JSON_PROXY);
251 RegisterSchemaResource("scriptBadge", IDR_EXTENSION_API_JSON_SCRIPTBADGE); 251 RegisterSchemaResource("scriptBadge", IDR_EXTENSION_API_JSON_SCRIPTBADGE);
252 RegisterSchemaResource("ttsEngine", IDR_EXTENSION_API_JSON_TTSENGINE); 252 RegisterSchemaResource("ttsEngine", IDR_EXTENSION_API_JSON_TTSENGINE);
253 RegisterSchemaResource("tts", IDR_EXTENSION_API_JSON_TTS); 253 RegisterSchemaResource("tts", IDR_EXTENSION_API_JSON_TTS);
254 RegisterSchemaResource("types", IDR_EXTENSION_API_JSON_TYPES); 254 RegisterSchemaResource("types", IDR_EXTENSION_API_JSON_TYPES);
255 RegisterSchemaResource("types.private", IDR_EXTENSION_API_JSON_TYPES_PRIVATE); 255 RegisterSchemaResource("types.private", IDR_EXTENSION_API_JSON_TYPES_PRIVATE);
256 RegisterSchemaResource("webRequestInternal",
257 IDR_EXTENSION_API_JSON_WEBREQUESTINTERNAL);
258 RegisterSchemaResource("webstore", IDR_EXTENSION_API_JSON_WEBSTORE); 256 RegisterSchemaResource("webstore", IDR_EXTENSION_API_JSON_WEBSTORE);
259 RegisterSchemaResource("webViewRequest", 257 RegisterSchemaResource("webViewRequest",
260 IDR_EXTENSION_API_JSON_WEBVIEW_REQUEST); 258 IDR_EXTENSION_API_JSON_WEBVIEW_REQUEST);
261 259
262 default_configuration_initialized_ = true; 260 default_configuration_initialized_ = true;
263 } 261 }
264 262
265 void ExtensionAPI::RegisterSchemaResource(const std::string& name, 263 void ExtensionAPI::RegisterSchemaResource(const std::string& name,
266 int resource_id) { 264 int resource_id) {
267 unloaded_schemas_[name] = resource_id; 265 unloaded_schemas_[name] = resource_id;
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
415 break; 413 break;
416 414
417 api_name_candidate = api_name_candidate.substr(0, last_dot_index); 415 api_name_candidate = api_name_candidate.substr(0, last_dot_index);
418 } 416 }
419 417
420 *child_name = ""; 418 *child_name = "";
421 return std::string(); 419 return std::string();
422 } 420 }
423 421
424 } // namespace extensions 422 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/common/extensions_api_resources.grd ('k') | extensions/common/permissions/api_permission.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698