| 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 370 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 381 gfx::Rect resizer_rect, | 381 gfx::Rect resizer_rect, |
| 382 bool is_fullscreen) { | 382 bool is_fullscreen) { |
| 383 ViewMsg_Resize_Params params; | 383 ViewMsg_Resize_Params params; |
| 384 params.screen_info = blink::WebScreenInfo(); | 384 params.screen_info = blink::WebScreenInfo(); |
| 385 params.new_size = new_size; | 385 params.new_size = new_size; |
| 386 params.physical_backing_size = new_size; | 386 params.physical_backing_size = new_size; |
| 387 params.top_controls_height = 0.f; | 387 params.top_controls_height = 0.f; |
| 388 params.top_controls_shrink_blink_size = false; | 388 params.top_controls_shrink_blink_size = false; |
| 389 params.resizer_rect = resizer_rect; | 389 params.resizer_rect = resizer_rect; |
| 390 params.is_fullscreen = is_fullscreen; | 390 params.is_fullscreen = is_fullscreen; |
| 391 params.display_mode = blink::WebDisplayModeBrowser; |
| 391 scoped_ptr<IPC::Message> resize_message(new ViewMsg_Resize(0, params)); | 392 scoped_ptr<IPC::Message> resize_message(new ViewMsg_Resize(0, params)); |
| 392 OnMessageReceived(*resize_message); | 393 OnMessageReceived(*resize_message); |
| 393 } | 394 } |
| 394 | 395 |
| 395 bool RenderViewTest::OnMessageReceived(const IPC::Message& msg) { | 396 bool RenderViewTest::OnMessageReceived(const IPC::Message& msg) { |
| 396 RenderViewImpl* impl = static_cast<RenderViewImpl*>(view_); | 397 RenderViewImpl* impl = static_cast<RenderViewImpl*>(view_); |
| 397 return impl->OnMessageReceived(msg); | 398 return impl->OnMessageReceived(msg); |
| 398 } | 399 } |
| 399 | 400 |
| 400 void RenderViewTest::DidNavigateWithinPage(blink::WebLocalFrame* frame, | 401 void RenderViewTest::DidNavigateWithinPage(blink::WebLocalFrame* frame, |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 454 impl->GetMainRenderFrame()->OnNavigate(common_params, StartNavigationParams(), | 455 impl->GetMainRenderFrame()->OnNavigate(common_params, StartNavigationParams(), |
| 455 CommitNavigationParams(), | 456 CommitNavigationParams(), |
| 456 history_params); | 457 history_params); |
| 457 | 458 |
| 458 // The load actually happens asynchronously, so we pump messages to process | 459 // The load actually happens asynchronously, so we pump messages to process |
| 459 // the pending continuation. | 460 // the pending continuation. |
| 460 FrameLoadWaiter(view_->GetMainRenderFrame()).Wait(); | 461 FrameLoadWaiter(view_->GetMainRenderFrame()).Wait(); |
| 461 } | 462 } |
| 462 | 463 |
| 463 } // namespace content | 464 } // namespace content |
| OLD | NEW |