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

Unified Diff: content/browser/renderer_host/render_view_host.cc

Issue 6735004: Move extension messages to their own file and add a RenderViewObserver to start moving the extens... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 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: content/browser/renderer_host/render_view_host.cc
===================================================================
--- content/browser/renderer_host/render_view_host.cc (revision 79468)
+++ content/browser/renderer_host/render_view_host.cc (working copy)
@@ -23,6 +23,7 @@
#include "chrome/common/bindings_policy.h"
#include "chrome/common/chrome_constants.h"
#include "chrome/common/chrome_switches.h"
+#include "chrome/common/extensions/extension_messages.h"
#include "chrome/common/net/url_request_context_getter.h"
#include "chrome/common/render_messages.h"
#include "chrome/common/print_messages.h"
@@ -565,7 +566,7 @@
}
void RenderViewHost::GetApplicationInfo(int32 page_id) {
- Send(new ViewMsg_GetApplicationInfo(routing_id(), page_id));
+ Send(new ExtensionMsg_GetApplicationInfo(routing_id(), page_id));
}
void RenderViewHost::CaptureSnapshot() {
@@ -772,10 +773,9 @@
IPC_MESSAGE_HANDLER(ViewHostMsg_TakeFocus, OnTakeFocus)
IPC_MESSAGE_HANDLER(ViewHostMsg_AddMessageToConsole, OnAddMessageToConsole)
IPC_MESSAGE_HANDLER(ViewHostMsg_ShouldClose_ACK, OnMsgShouldCloseACK)
- IPC_MESSAGE_HANDLER(ViewHostMsg_ExtensionRequest, OnExtensionRequest)
+ IPC_MESSAGE_HANDLER(ExtensionHostMsg_Request, OnExtensionRequest)
IPC_MESSAGE_HANDLER(ViewHostMsg_SelectionChanged, OnMsgSelectionChanged)
- IPC_MESSAGE_HANDLER(ViewHostMsg_ExtensionPostMessage,
- OnExtensionPostMessage)
+ IPC_MESSAGE_HANDLER(ExtensionHostMsg_PostMessage, OnExtensionPostMessage)
IPC_MESSAGE_HANDLER(ViewHostMsg_AccessibilityNotifications,
OnAccessibilityNotifications)
IPC_MESSAGE_HANDLER(ViewHostMsg_OnCSSInserted, OnCSSInserted)
@@ -1115,7 +1115,7 @@
}
}
- ViewHostMsg_DomMessage_Params params;
+ ExtensionHostMsg_DomMessage_Params params;
params.name = message;
if (value.get())
params.arguments.Swap(static_cast<ListValue*>(value.get()));
@@ -1399,7 +1399,7 @@
}
void RenderViewHost::OnExtensionRequest(
- const ViewHostMsg_DomMessage_Params& params) {
+ const ExtensionHostMsg_DomMessage_Params& params) {
if (!ChildProcessSecurityPolicy::GetInstance()->
HasExtensionBindings(process()->id())) {
// This can happen if someone uses window.open() to open an extension URL
@@ -1414,8 +1414,8 @@
void RenderViewHost::SendExtensionResponse(int request_id, bool success,
const std::string& response,
const std::string& error) {
- Send(new ViewMsg_ExtensionResponse(routing_id(), request_id, success,
- response, error));
+ Send(new ExtensionMsg_Response(
+ routing_id(), request_id, success, response, error));
}
void RenderViewHost::BlockExtensionRequest(int request_id) {
« no previous file with comments | « content/browser/renderer_host/render_view_host.h ('k') | content/browser/renderer_host/render_view_host_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698