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

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

Issue 11571014: Lazy load chrome.* APIs (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: android compilation Created 7 years, 9 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/send_request_natives.h
diff --git a/chrome/renderer/extensions/send_request_natives.h b/chrome/renderer/extensions/send_request_natives.h
index d92ffe39cbd8dfbf82d4637f7fab0567012d5532..1e3437a5e6a120d16536ddc1d2e746f3b3a40d1b 100644
--- a/chrome/renderer/extensions/send_request_natives.h
+++ b/chrome/renderer/extensions/send_request_natives.h
@@ -11,22 +11,31 @@
#include "v8/include/v8.h"
namespace extensions {
+class ChromeV8Context;
class RequestSender;
// Native functions exposed to extensions via JS for calling API functions in
// the browser.
class SendRequestNatives : public ChromeV8Extension {
public:
- SendRequestNatives(Dispatcher* dispatcher, RequestSender* request_sender);
+ SendRequestNatives(Dispatcher* dispatcher,
+ RequestSender* request_sender,
+ ChromeV8Context* context);
private:
v8::Handle<v8::Value> GetNextRequestId(const v8::Arguments& args);
+
// Starts an API request to the browser, with an optional callback. The
// callback will be dispatched to EventBindings::HandleResponse.
v8::Handle<v8::Value> StartRequest(const v8::Arguments& args);
+ // Gets a reference to an object's global object.
+ v8::Handle<v8::Value> GetGlobal(const v8::Arguments& args);
+
RequestSender* request_sender_;
+ ChromeV8Context* context_;
+
DISALLOW_COPY_AND_ASSIGN(SendRequestNatives);
};
« no previous file with comments | « chrome/renderer/extensions/runtime_custom_bindings.cc ('k') | chrome/renderer/extensions/send_request_natives.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698