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