summaryrefslogtreecommitdiffstats
path: root/chrome/renderer/devtools_agent.cc
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/renderer/devtools_agent.cc')
-rw-r--r--chrome/renderer/devtools_agent.cc43
1 files changed, 33 insertions, 10 deletions
diff --git a/chrome/renderer/devtools_agent.cc b/chrome/renderer/devtools_agent.cc
index 11211fd..d1e81e2 100644
--- a/chrome/renderer/devtools_agent.cc
+++ b/chrome/renderer/devtools_agent.cc
@@ -9,16 +9,13 @@
#include "chrome/renderer/devtools_agent_filter.h"
#include "chrome/renderer/render_view.h"
#include "third_party/WebKit/WebKit/chromium/public/WebDevToolsAgent.h"
-#include "third_party/WebKit/WebKit/chromium/public/WebDevToolsMessageData.h"
#include "third_party/WebKit/WebKit/chromium/public/WebPoint.h"
#include "third_party/WebKit/WebKit/chromium/public/WebString.h"
-#include "webkit/glue/devtools/devtools_message_data.h"
#include "webkit/glue/glue_util.h"
using WebKit::WebDevToolsAgent;
using WebKit::WebPoint;
using WebKit::WebString;
-using WebKit::WebVector;
using WebKit::WebView;
// static
@@ -56,11 +53,19 @@ bool DevToolsAgent::OnMessageReceived(const IPC::Message& message) {
return handled;
}
-void DevToolsAgent::sendMessageToFrontend(
- const WebKit::WebDevToolsMessageData& data) {
+void DevToolsAgent::sendMessageToFrontend(const WebString& class_name,
+ const WebString& method_name,
+ const WebString& param1,
+ const WebString& param2,
+ const WebString& param3) {
IPC::Message* m = new ViewHostMsg_ForwardToDevToolsClient(
routing_id_,
- DevToolsClientMsg_RpcMessage(DevToolsMessageData(data)));
+ DevToolsClientMsg_RpcMessage(
+ class_name.utf8(),
+ method_name.utf8(),
+ param1.utf8(),
+ param2.utf8(),
+ param3.utf8()));
render_view_->Send(m);
}
@@ -108,10 +113,19 @@ void DevToolsAgent::OnDetach() {
}
}
-void DevToolsAgent::OnRpcMessage(const DevToolsMessageData& data) {
+void DevToolsAgent::OnRpcMessage(const std::string& class_name,
+ const std::string& method_name,
+ const std::string& param1,
+ const std::string& param2,
+ const std::string& param3) {
WebDevToolsAgent* web_agent = GetWebAgent();
if (web_agent) {
- web_agent->dispatchMessageFromFrontend(data.ToWebDevToolsMessageData());
+ web_agent->dispatchMessageFromFrontend(
+ WebString::fromUTF8(class_name),
+ WebString::fromUTF8(method_name),
+ WebString::fromUTF8(param1),
+ WebString::fromUTF8(param2),
+ WebString::fromUTF8(param3));
}
}
@@ -141,6 +155,15 @@ WebDevToolsAgent* DevToolsAgent::GetWebAgent() {
// static
void WebKit::WebDevToolsAgentClient::sendMessageToFrontendOnIOThread(
- const WebDevToolsMessageData& data) {
- DevToolsAgentFilter::SendRpcMessage(DevToolsMessageData(data));
+ const WebString& class_name,
+ const WebString& method_name,
+ const WebString& param1,
+ const WebString& param2,
+ const WebString& param3) {
+ DevToolsAgentFilter::SendRpcMessage(
+ class_name.utf8(),
+ method_name.utf8(),
+ param1.utf8(),
+ param2.utf8(),
+ param3.utf8());
}