| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "content/public/test/render_view_test.h" | 5 #include "content/public/test/render_view_test.h" |
| 6 | 6 |
| 7 #include "base/run_loop.h" | 7 #include "base/run_loop.h" |
| 8 #include "content/common/dom_storage/dom_storage_types.h" | 8 #include "content/common/dom_storage/dom_storage_types.h" |
| 9 #include "content/common/frame_messages.h" | 9 #include "content/common/frame_messages.h" |
| 10 #include "content/common/input_messages.h" | 10 #include "content/common/input_messages.h" |
| (...skipping 339 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 350 params.is_fullscreen = is_fullscreen; | 350 params.is_fullscreen = is_fullscreen; |
| 351 scoped_ptr<IPC::Message> resize_message(new ViewMsg_Resize(0, params)); | 351 scoped_ptr<IPC::Message> resize_message(new ViewMsg_Resize(0, params)); |
| 352 OnMessageReceived(*resize_message); | 352 OnMessageReceived(*resize_message); |
| 353 } | 353 } |
| 354 | 354 |
| 355 bool RenderViewTest::OnMessageReceived(const IPC::Message& msg) { | 355 bool RenderViewTest::OnMessageReceived(const IPC::Message& msg) { |
| 356 RenderViewImpl* impl = static_cast<RenderViewImpl*>(view_); | 356 RenderViewImpl* impl = static_cast<RenderViewImpl*>(view_); |
| 357 return impl->OnMessageReceived(msg); | 357 return impl->OnMessageReceived(msg); |
| 358 } | 358 } |
| 359 | 359 |
| 360 void RenderViewTest::DidNavigateWithinPage(blink::WebFrame* frame, | 360 void RenderViewTest::DidNavigateWithinPage(blink::WebLocalFrame* frame, |
| 361 bool is_new_navigation) { | 361 bool is_new_navigation) { |
| 362 RenderViewImpl* impl = static_cast<RenderViewImpl*>(view_); | 362 RenderViewImpl* impl = static_cast<RenderViewImpl*>(view_); |
| 363 impl->didNavigateWithinPage(frame, is_new_navigation); | 363 impl->didNavigateWithinPage(frame, is_new_navigation); |
| 364 } | 364 } |
| 365 | 365 |
| 366 void RenderViewTest::SendContentStateImmediately() { | 366 void RenderViewTest::SendContentStateImmediately() { |
| 367 RenderViewImpl* impl = static_cast<RenderViewImpl*>(view_); | 367 RenderViewImpl* impl = static_cast<RenderViewImpl*>(view_); |
| 368 impl->set_send_content_state_immediately(true); | 368 impl->set_send_content_state_immediately(true); |
| 369 } | 369 } |
| 370 | 370 |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 407 FrameMsg_Navigate navigate_message(impl->main_render_frame()->GetRoutingID(), | 407 FrameMsg_Navigate navigate_message(impl->main_render_frame()->GetRoutingID(), |
| 408 navigate_params); | 408 navigate_params); |
| 409 impl->main_render_frame()->OnMessageReceived(navigate_message); | 409 impl->main_render_frame()->OnMessageReceived(navigate_message); |
| 410 | 410 |
| 411 // The load actually happens asynchronously, so we pump messages to process | 411 // The load actually happens asynchronously, so we pump messages to process |
| 412 // the pending continuation. | 412 // the pending continuation. |
| 413 ProcessPendingMessages(); | 413 ProcessPendingMessages(); |
| 414 } | 414 } |
| 415 | 415 |
| 416 } // namespace content | 416 } // namespace content |
| OLD | NEW |