OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef CONTENT_SHELL_RENDERER_TEST_RUNNER_WEB_FRAME_TEST_PROXY_H_ | 5 #ifndef CONTENT_SHELL_RENDERER_TEST_RUNNER_WEB_FRAME_TEST_PROXY_H_ |
6 #define CONTENT_SHELL_RENDERER_TEST_RUNNER_WEB_FRAME_TEST_PROXY_H_ | 6 #define CONTENT_SHELL_RENDERER_TEST_RUNNER_WEB_FRAME_TEST_PROXY_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "content/shell/renderer/test_runner/mock_screen_orientation_client.h" | 9 #include "content/shell/renderer/test_runner/mock_screen_orientation_client.h" |
| 10 #include "content/shell/renderer/test_runner/mock_web_speech_recognizer.h" |
10 #include "content/shell/renderer/test_runner/test_interfaces.h" | 11 #include "content/shell/renderer/test_runner/test_interfaces.h" |
11 #include "content/shell/renderer/test_runner/test_runner.h" | 12 #include "content/shell/renderer/test_runner/test_runner.h" |
12 #include "content/shell/renderer/test_runner/web_test_delegate.h" | 13 #include "content/shell/renderer/test_runner/web_test_delegate.h" |
13 #include "content/shell/renderer/test_runner/web_test_proxy.h" | 14 #include "content/shell/renderer/test_runner/web_test_proxy.h" |
14 #include "content/test/test_media_stream_renderer_factory.h" | 15 #include "content/test/test_media_stream_renderer_factory.h" |
15 #include "third_party/WebKit/public/platform/WebString.h" | 16 #include "third_party/WebKit/public/platform/WebString.h" |
16 | 17 |
17 namespace content { | 18 namespace content { |
18 | 19 |
19 // Templetized wrapper around RenderFrameImpl objects, which implement | 20 // Templetized wrapper around RenderFrameImpl objects, which implement |
(...skipping 13 matching lines...) Expand all Loading... |
33 blink::WebPlugin* plugin = base_proxy_->CreatePlugin(frame, params); | 34 blink::WebPlugin* plugin = base_proxy_->CreatePlugin(frame, params); |
34 if (plugin) | 35 if (plugin) |
35 return plugin; | 36 return plugin; |
36 return Base::createPlugin(frame, params); | 37 return Base::createPlugin(frame, params); |
37 } | 38 } |
38 | 39 |
39 virtual blink::WebScreenOrientationClient* webScreenOrientationClient() { | 40 virtual blink::WebScreenOrientationClient* webScreenOrientationClient() { |
40 return base_proxy_->GetScreenOrientationClientMock(); | 41 return base_proxy_->GetScreenOrientationClientMock(); |
41 } | 42 } |
42 | 43 |
| 44 virtual blink::WebSpeechRecognizer* speechRecognizer() { |
| 45 return base_proxy_->GetSpeechRecognizerMock(); |
| 46 } |
| 47 |
43 virtual void didAddMessageToConsole(const blink::WebConsoleMessage& message, | 48 virtual void didAddMessageToConsole(const blink::WebConsoleMessage& message, |
44 const blink::WebString& source_name, | 49 const blink::WebString& source_name, |
45 unsigned source_line, | 50 unsigned source_line, |
46 const blink::WebString& stack_trace) { | 51 const blink::WebString& stack_trace) { |
47 base_proxy_->DidAddMessageToConsole(message, source_name, source_line); | 52 base_proxy_->DidAddMessageToConsole(message, source_name, source_line); |
48 Base::didAddMessageToConsole( | 53 Base::didAddMessageToConsole( |
49 message, source_name, source_line, stack_trace); | 54 message, source_name, source_line, stack_trace); |
50 } | 55 } |
51 | 56 |
52 virtual bool canCreatePluginWithoutRenderer( | 57 virtual bool canCreatePluginWithoutRenderer( |
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
296 #endif | 301 #endif |
297 | 302 |
298 WebTestProxyBase* base_proxy_; | 303 WebTestProxyBase* base_proxy_; |
299 | 304 |
300 DISALLOW_COPY_AND_ASSIGN(WebFrameTestProxy); | 305 DISALLOW_COPY_AND_ASSIGN(WebFrameTestProxy); |
301 }; | 306 }; |
302 | 307 |
303 } // namespace content | 308 } // namespace content |
304 | 309 |
305 #endif // CONTENT_SHELL_RENDERER_TEST_RUNNER_WEB_FRAME_TEST_PROXY_H_ | 310 #endif // CONTENT_SHELL_RENDERER_TEST_RUNNER_WEB_FRAME_TEST_PROXY_H_ |
OLD | NEW |