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

Unified Diff: chrome/renderer/extensions/dispatcher.h

Issue 11571014: Lazy load chrome.* APIs (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: comments/TODOs Created 7 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: chrome/renderer/extensions/dispatcher.h
diff --git a/chrome/renderer/extensions/dispatcher.h b/chrome/renderer/extensions/dispatcher.h
index 2676b3b7b4ad9771f60ba2899fb44e5fd53b060d..f0e71acf745ac699fc7c33ed123380c5b96b5a66 100644
--- a/chrome/renderer/extensions/dispatcher.h
+++ b/chrome/renderer/extensions/dispatcher.h
@@ -185,6 +185,9 @@ class Dispatcher : public content::RenderProcessObserver {
void RegisterNativeHandlers(ModuleSystem* module_system,
ChromeV8Context* context);
+ void RegisterSchemaGeneratedBindings(ModuleSystem* module_system,
+ ChromeV8Context* context,
+ v8::Handle<v8::Context> v8_context);
// Inserts static source code into |source_map_|.
void PopulateSourceMap();
@@ -207,6 +210,19 @@ class Dispatcher : public content::RenderProcessObserver {
int extension_group,
const ExtensionURLInfo& url_info);
+ typedef void (ModuleSystem::*LazyFieldSetter)(v8::Handle<v8::Object>,
+ const std::string&,
+ const std::string&,
+ const std::string&);
+ // Sets up a chain of objects for APIs like chrome.systemInfo.storage so they
+ // don't have to be accessed like chrome['systemInfo.storage'].
+ void SetUpChainedField(v8::Handle<v8::Object> object,
+ const std::string& field,
+ const std::string& module_name,
+ const std::string& module_field,
+ ModuleSystem* module_system,
+ LazyFieldSetter setter);
+
// True if this renderer is running extensions.
bool is_extension_process_;

Powered by Google App Engine
This is Rietveld 408576698