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/browser/renderer_host/render_widget_host_impl.h" | 5 #include "content/browser/renderer_host/render_widget_host_impl.h" |
6 | 6 |
7 #include <math.h> | 7 #include <math.h> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/auto_reset.h" | 10 #include "base/auto_reset.h" |
(...skipping 1498 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1509 frame.metadata.root_scroll_offset, frame.metadata.page_scale_factor); | 1509 frame.metadata.root_scroll_offset, frame.metadata.page_scale_factor); |
1510 gfx::SizeF content_size = ScaleSize( | 1510 gfx::SizeF content_size = ScaleSize( |
1511 frame.metadata.root_layer_size, frame.metadata.page_scale_factor); | 1511 frame.metadata.root_layer_size, frame.metadata.page_scale_factor); |
1512 | 1512 |
1513 if (view_) { | 1513 if (view_) { |
1514 view_->UpdateFrameInfo( | 1514 view_->UpdateFrameInfo( |
1515 gfx::ToRoundedVector2d(scroll_offset), | 1515 gfx::ToRoundedVector2d(scroll_offset), |
1516 frame.metadata.page_scale_factor, | 1516 frame.metadata.page_scale_factor, |
1517 frame.metadata.min_page_scale_factor, | 1517 frame.metadata.min_page_scale_factor, |
1518 frame.metadata.max_page_scale_factor, | 1518 frame.metadata.max_page_scale_factor, |
1519 gfx::ToCeiledSize(content_size)); | 1519 gfx::ToCeiledSize(content_size), |
| 1520 frame.metadata.location_bar_offset, |
| 1521 frame.metadata.content_offset); |
1520 } | 1522 } |
1521 #endif | 1523 #endif |
1522 } | 1524 } |
1523 | 1525 |
1524 void RenderWidgetHostImpl::OnUpdateRect( | 1526 void RenderWidgetHostImpl::OnUpdateRect( |
1525 const ViewHostMsg_UpdateRect_Params& params) { | 1527 const ViewHostMsg_UpdateRect_Params& params) { |
1526 TRACE_EVENT0("renderer_host", "RenderWidgetHostImpl::OnUpdateRect"); | 1528 TRACE_EVENT0("renderer_host", "RenderWidgetHostImpl::OnUpdateRect"); |
1527 TimeTicks paint_start = TimeTicks::Now(); | 1529 TimeTicks paint_start = TimeTicks::Now(); |
1528 | 1530 |
1529 // Update our knowledge of the RenderWidget's size. | 1531 // Update our knowledge of the RenderWidget's size. |
(...skipping 806 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2336 return; | 2338 return; |
2337 | 2339 |
2338 OnRenderAutoResized(new_size); | 2340 OnRenderAutoResized(new_size); |
2339 } | 2341 } |
2340 | 2342 |
2341 void RenderWidgetHostImpl::DetachDelegate() { | 2343 void RenderWidgetHostImpl::DetachDelegate() { |
2342 delegate_ = NULL; | 2344 delegate_ = NULL; |
2343 } | 2345 } |
2344 | 2346 |
2345 } // namespace content | 2347 } // namespace content |
OLD | NEW |