| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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/renderer/gpu/render_widget_compositor.h" | 5 #include "content/renderer/gpu/render_widget_compositor.h" |
| 6 | 6 |
| 7 #include <limits> | 7 #include <limits> |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #if defined(OS_ANDROID) | 10 #if defined(OS_ANDROID) |
| (...skipping 631 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 642 void RenderWidgetCompositor::Layout() { | 642 void RenderWidgetCompositor::Layout() { |
| 643 widget_->webwidget()->layout(); | 643 widget_->webwidget()->layout(); |
| 644 } | 644 } |
| 645 | 645 |
| 646 void RenderWidgetCompositor::ApplyScrollAndScale( | 646 void RenderWidgetCompositor::ApplyScrollAndScale( |
| 647 const gfx::Vector2d& scroll_delta, | 647 const gfx::Vector2d& scroll_delta, |
| 648 float page_scale) { | 648 float page_scale) { |
| 649 widget_->webwidget()->applyScrollAndScale(scroll_delta, page_scale); | 649 widget_->webwidget()->applyScrollAndScale(scroll_delta, page_scale); |
| 650 } | 650 } |
| 651 | 651 |
| 652 scoped_ptr<cc::OutputSurface> RenderWidgetCompositor::CreateOutputSurface( | 652 void RenderWidgetCompositor::RequestNewOutputSurface(bool fallback) { |
| 653 bool fallback) { | 653 layer_tree_host_->SetOutputSurface(widget_->CreateOutputSurface(fallback)); |
| 654 return widget_->CreateOutputSurface(fallback); | |
| 655 } | 654 } |
| 656 | 655 |
| 657 void RenderWidgetCompositor::DidInitializeOutputSurface() { | 656 void RenderWidgetCompositor::DidInitializeOutputSurface() { |
| 658 } | 657 } |
| 659 | 658 |
| 660 void RenderWidgetCompositor::WillCommit() { | 659 void RenderWidgetCompositor::WillCommit() { |
| 661 widget_->InstrumentWillComposite(); | 660 widget_->InstrumentWillComposite(); |
| 662 } | 661 } |
| 663 | 662 |
| 664 void RenderWidgetCompositor::DidCommit() { | 663 void RenderWidgetCompositor::DidCommit() { |
| (...skipping 23 matching lines...) Expand all Loading... |
| 688 cc::ContextProvider* provider = | 687 cc::ContextProvider* provider = |
| 689 RenderThreadImpl::current()->SharedMainThreadContextProvider().get(); | 688 RenderThreadImpl::current()->SharedMainThreadContextProvider().get(); |
| 690 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM(); | 689 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM(); |
| 691 } | 690 } |
| 692 | 691 |
| 693 bool RenderWidgetCompositor::usesGpuRasterization() { | 692 bool RenderWidgetCompositor::usesGpuRasterization() { |
| 694 return layer_tree_host_->UseGpuRasterization(); | 693 return layer_tree_host_->UseGpuRasterization(); |
| 695 } | 694 } |
| 696 | 695 |
| 697 } // namespace content | 696 } // namespace content |
| OLD | NEW |