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

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

Issue 11547033: Implement declarativeContent API. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years 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/module_system.h
diff --git a/chrome/renderer/extensions/module_system.h b/chrome/renderer/extensions/module_system.h
index 4f790842aec9f0a5095e355b90c10a2d991a837b..339e1bf02f1ba1286802e2437bc57e66e67d2054 100644
--- a/chrome/renderer/extensions/module_system.h
+++ b/chrome/renderer/extensions/module_system.h
@@ -81,6 +81,13 @@ class ModuleSystem : public NativeHandler {
void CallModuleMethod(const std::string& module_name,
const std::string& method_name);
+ // Calls the specified method exported by the specified module. This is
+ // equivalent to calling require('module_name').method_name(args) from JS.
+ v8::Local<v8::Value> CallModuleMethod(
+ const std::string& module_name,
+ const std::string& method_name,
+ std::vector<v8::Handle<v8::Value> >* args);
+
// Register |native_handler| as a potential target for requireNative(), so
// calls to requireNative(|name|) from JS will return a new object created by
// |native_handler|.

Powered by Google App Engine
This is Rietveld 408576698