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/WebTestDelegate.h" | 9 #include "content/shell/renderer/test_runner/WebTestDelegate.h" |
10 #include "content/shell/renderer/test_runner/mock_screen_orientation_client.h" | 10 #include "content/shell/renderer/test_runner/mock_screen_orientation_client.h" |
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
168 virtual bool runModalBeforeUnloadDialog(bool is_reload, | 168 virtual bool runModalBeforeUnloadDialog(bool is_reload, |
169 const blink::WebString& message) { | 169 const blink::WebString& message) { |
170 base_proxy_->delegate_->printMessage(std::string("CONFIRM NAVIGATION: ") + | 170 base_proxy_->delegate_->printMessage(std::string("CONFIRM NAVIGATION: ") + |
171 message.utf8().data() + "\n"); | 171 message.utf8().data() + "\n"); |
172 return !base_proxy_->test_interfaces_->GetTestRunner() | 172 return !base_proxy_->test_interfaces_->GetTestRunner() |
173 ->shouldStayOnPageAfterHandlingBeforeUnload(); | 173 ->shouldStayOnPageAfterHandlingBeforeUnload(); |
174 } | 174 } |
175 | 175 |
176 virtual void showContextMenu( | 176 virtual void showContextMenu( |
177 const blink::WebContextMenuData& context_menu_data) { | 177 const blink::WebContextMenuData& context_menu_data) { |
178 base_proxy_->ShowContextMenu(Base::GetWebFrame()->toWebLocalFrame(), | 178 base_proxy_->ShowContextMenu(Base::GetWebFrame(), |
179 context_menu_data); | 179 context_menu_data); |
180 Base::showContextMenu(context_menu_data); | 180 Base::showContextMenu(context_menu_data); |
181 } | 181 } |
182 | 182 |
183 virtual void didDetectXSS(blink::WebLocalFrame* frame, | 183 virtual void didDetectXSS(blink::WebLocalFrame* frame, |
184 const blink::WebURL& insecure_url, | 184 const blink::WebURL& insecure_url, |
185 bool did_block_entire_page) { | 185 bool did_block_entire_page) { |
186 // This is not implemented in RenderFrameImpl, so need to explicitly call | 186 // This is not implemented in RenderFrameImpl, so need to explicitly call |
187 // into the base proxy. | 187 // into the base proxy. |
188 base_proxy_->DidDetectXSS(frame, insecure_url, did_block_entire_page); | 188 base_proxy_->DidDetectXSS(frame, insecure_url, did_block_entire_page); |
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
296 #endif | 296 #endif |
297 | 297 |
298 WebTestProxyBase* base_proxy_; | 298 WebTestProxyBase* base_proxy_; |
299 | 299 |
300 DISALLOW_COPY_AND_ASSIGN(WebFrameTestProxy); | 300 DISALLOW_COPY_AND_ASSIGN(WebFrameTestProxy); |
301 }; | 301 }; |
302 | 302 |
303 } // namespace content | 303 } // namespace content |
304 | 304 |
305 #endif // CONTENT_SHELL_RENDERER_TEST_RUNNER_WEB_FRAME_TEST_PROXY_H_ | 305 #endif // CONTENT_SHELL_RENDERER_TEST_RUNNER_WEB_FRAME_TEST_PROXY_H_ |
OLD | NEW |