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

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

Issue 9386001: Implement a module system for the extension bindings JS. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 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
« no previous file with comments | « chrome/chrome_renderer.gypi ('k') | chrome/renderer/extensions/app_bindings.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/extensions/app_bindings.h
diff --git a/chrome/renderer/extensions/app_bindings.h b/chrome/renderer/extensions/app_bindings.h
index 9a77fcb3e97e6b05d65d14fcb955d1c3e71a3212..e27c770f3c6f0499303b94e4e3b2f6bac2ed7d3d 100644
--- a/chrome/renderer/extensions/app_bindings.h
+++ b/chrome/renderer/extensions/app_bindings.h
@@ -14,21 +14,34 @@
#include "base/compiler_specific.h"
#include "chrome/renderer/extensions/chrome_v8_extension.h"
+#include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h"
class ChromeV8Context;
// Implements the chrome.app JavaScript object.
//
// TODO(aa): Add unit testing for this class.
-class AppBindings : public ChromeV8Extension {
+class AppBindings : public ChromeV8Extension, public ChromeV8ExtensionHandler {
public:
- explicit AppBindings(ExtensionDispatcher* dispatcher);
-
- protected:
- virtual ChromeV8ExtensionHandler* CreateHandler(
- ChromeV8Context* context) OVERRIDE;
+ explicit AppBindings(ExtensionDispatcher* dispatcher,
+ ChromeV8Context* context);
private:
+ // IPC::Channel::Listener
+ virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
+
+ v8::Handle<v8::Value> GetIsInstalled(const v8::Arguments& args);
+ v8::Handle<v8::Value> Install(const v8::Arguments& args);
+ v8::Handle<v8::Value> GetDetails(const v8::Arguments& args);
+ v8::Handle<v8::Value> GetDetailsForFrame(const v8::Arguments& args);
+ v8::Handle<v8::Value> GetAppNotifyChannel(const v8::Arguments& args);
+
+ v8::Handle<v8::Value> GetDetailsForFrameImpl(WebKit::WebFrame* frame);
+
+ void OnGetAppNotifyChannelResponse(const std::string& channel_id,
+ const std::string& error,
+ int callback_id);
+
DISALLOW_COPY_AND_ASSIGN(AppBindings);
};
« no previous file with comments | « chrome/chrome_renderer.gypi ('k') | chrome/renderer/extensions/app_bindings.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698