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

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

Issue 240603003: Remove ChromeV8Extension & most of ChromeV8Context (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: cleanup 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 side-by-side diff with in-line comments
Download patch
Index: chrome/renderer/extensions/messaging_bindings.h
diff --git a/chrome/renderer/extensions/messaging_bindings.h b/chrome/renderer/extensions/messaging_bindings.h
index c9ebd83aae5daf3f0e4c8974917c16dfa419f711..ab3c093f4995d0e4510d66f328e7296984c79ddf 100644
--- a/chrome/renderer/extensions/messaging_bindings.h
+++ b/chrome/renderer/extensions/messaging_bindings.h
@@ -7,7 +7,7 @@
#include <string>
-#include "chrome/renderer/extensions/chrome_v8_context_set.h"
+#include "extensions/renderer/script_context_set.h"
namespace base {
class DictionaryValue;
@@ -22,9 +22,9 @@ class Extension;
}
namespace extensions {
-class ChromeV8Extension;
class Dispatcher;
struct Message;
+class ObjectBackedNativeHandler;
// Manually implements JavaScript bindings for extension messaging.
//
@@ -34,35 +34,33 @@ struct Message;
class MessagingBindings {
public:
// Creates an instance of the extension.
- static ChromeV8Extension* Get(Dispatcher* dispatcher,
- ChromeV8Context* context);
+ static ObjectBackedNativeHandler* Get(Dispatcher* dispatcher,
+ ScriptContext* context);
// Dispatches the onConnect content script messaging event to some contexts
// in |contexts|. If |restrict_to_render_view| is specified, only contexts in
// that render view will receive the message.
- static void DispatchOnConnect(
- const ChromeV8ContextSet::ContextSet& contexts,
- int target_port_id,
- const std::string& channel_name,
- const base::DictionaryValue& source_tab,
- const std::string& source_extension_id,
- const std::string& target_extension_id,
- const GURL& source_url,
- const std::string& tls_channel_id,
- content::RenderView* restrict_to_render_view);
+ static void DispatchOnConnect(const ScriptContextSet::ContextSet& contexts,
+ int target_port_id,
+ const std::string& channel_name,
+ const base::DictionaryValue& source_tab,
+ const std::string& source_extension_id,
+ const std::string& target_extension_id,
+ const GURL& source_url,
+ const std::string& tls_channel_id,
+ content::RenderView* restrict_to_render_view);
// Delivers a message sent using content script messaging to some of the
// contexts in |bindings_context_set|. If |restrict_to_render_view| is
// specified, only contexts in that render view will receive the message.
- static void DeliverMessage(
- const ChromeV8ContextSet::ContextSet& context_set,
- int target_port_id,
- const Message& message,
- content::RenderView* restrict_to_render_view);
+ static void DeliverMessage(const ScriptContextSet::ContextSet& context_set,
+ int target_port_id,
+ const Message& message,
+ content::RenderView* restrict_to_render_view);
// Dispatches the onDisconnect event in response to the channel being closed.
static void DispatchOnDisconnect(
- const ChromeV8ContextSet::ContextSet& context_set,
+ const ScriptContextSet::ContextSet& context_set,
int port_id,
const std::string& error_message,
content::RenderView* restrict_to_render_view);

Powered by Google App Engine
This is Rietveld 408576698