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

Side by Side Diff: webkit/tools/test_shell/test_shell_devtools_agent.cc

Issue 2609001: Add implementation for WebDevToolsAgentClient::debuggerScriptSource.... (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: '' Created 10 years, 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "webkit/tools/test_shell/test_shell_devtools_agent.h" 5 #include "webkit/tools/test_shell/test_shell_devtools_agent.h"
6 6
7 #include "base/message_loop.h" 7 #include "base/message_loop.h"
8 #include "grit/webkit_chromium_resources.h" 8 #include "grit/webkit_chromium_resources.h"
9 #include "third_party/WebKit/WebKit/chromium/public/WebDevToolsAgent.h" 9 #include "third_party/WebKit/WebKit/chromium/public/WebDevToolsAgent.h"
10 #include "third_party/WebKit/WebKit/chromium/public/WebView.h" 10 #include "third_party/WebKit/WebKit/chromium/public/WebView.h"
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 webkit_glue::GetDataResource(IDR_DEVTOOLS_INJECT_WEBKIT_JS); 65 webkit_glue::GetDataResource(IDR_DEVTOOLS_INJECT_WEBKIT_JS);
66 return WebCString(injectjsWebkit.as_string().c_str()); 66 return WebCString(injectjsWebkit.as_string().c_str());
67 } 67 }
68 68
69 WebCString TestShellDevToolsAgent::injectedScriptDispatcherSource() { 69 WebCString TestShellDevToolsAgent::injectedScriptDispatcherSource() {
70 base::StringPiece injectDispatchjs = 70 base::StringPiece injectDispatchjs =
71 webkit_glue::GetDataResource(IDR_DEVTOOLS_INJECT_DISPATCH_JS); 71 webkit_glue::GetDataResource(IDR_DEVTOOLS_INJECT_DISPATCH_JS);
72 return WebCString(injectDispatchjs.as_string().c_str()); 72 return WebCString(injectDispatchjs.as_string().c_str());
73 } 73 }
74 74
75 WebCString TestShellDevToolsAgent::debuggerScriptSource() {
76 base::StringPiece debuggerScriptjs =
77 webkit_glue::GetDataResource(IDR_DEVTOOLS_DEBUGGER_SCRIPT_JS);
78 return WebCString(debuggerScriptjs.as_string().c_str());
79 }
80
75 void TestShellDevToolsAgent::AsyncCall(const TestShellDevToolsCallArgs &args) { 81 void TestShellDevToolsAgent::AsyncCall(const TestShellDevToolsCallArgs &args) {
76 MessageLoop::current()->PostDelayedTask( 82 MessageLoop::current()->PostDelayedTask(
77 FROM_HERE, 83 FROM_HERE,
78 call_method_factory_.NewRunnableMethod(&TestShellDevToolsAgent::Call, 84 call_method_factory_.NewRunnableMethod(&TestShellDevToolsAgent::Call,
79 args), 85 args),
80 0); 86 0);
81 } 87 }
82 88
83 void TestShellDevToolsAgent::Call(const TestShellDevToolsCallArgs &args) { 89 void TestShellDevToolsAgent::Call(const TestShellDevToolsCallArgs &args) {
84 WebDevToolsAgent* web_agent = GetWebAgent(); 90 WebDevToolsAgent* web_agent = GetWebAgent();
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
126 return false; 132 return false;
127 agent->evaluateInWebInspector(call_id, WebString::fromUTF8(script)); 133 agent->evaluateInWebInspector(call_id, WebString::fromUTF8(script));
128 return true; 134 return true;
129 } 135 }
130 136
131 // static 137 // static
132 void WebKit::WebDevToolsAgentClient::sendMessageToFrontendOnIOThread( 138 void WebKit::WebDevToolsAgentClient::sendMessageToFrontendOnIOThread(
133 WebKit::WebDevToolsMessageData const &) { 139 WebKit::WebDevToolsMessageData const &) {
134 NOTIMPLEMENTED(); 140 NOTIMPLEMENTED();
135 } 141 }
OLDNEW
« no previous file with comments | « webkit/tools/test_shell/test_shell_devtools_agent.h ('k') | webkit/tools/test_shell/test_shell_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698