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 550 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
561 } | 561 } |
562 | 562 |
563 void RenderWidgetCompositor::Animate(double frame_begin_time) { | 563 void RenderWidgetCompositor::Animate(double frame_begin_time) { |
564 widget_->webwidget()->animate(frame_begin_time); | 564 widget_->webwidget()->animate(frame_begin_time); |
565 } | 565 } |
566 | 566 |
567 void RenderWidgetCompositor::Layout() { | 567 void RenderWidgetCompositor::Layout() { |
568 widget_->webwidget()->layout(); | 568 widget_->webwidget()->layout(); |
569 } | 569 } |
570 | 570 |
571 void RenderWidgetCompositor::ApplyScrollAndScale(gfx::Vector2d scroll_delta, | 571 void RenderWidgetCompositor::ApplyScrollAndScale( |
572 float page_scale) { | 572 const gfx::Vector2d& scroll_delta, |
| 573 float page_scale) { |
573 widget_->webwidget()->applyScrollAndScale(scroll_delta, page_scale); | 574 widget_->webwidget()->applyScrollAndScale(scroll_delta, page_scale); |
574 } | 575 } |
575 | 576 |
576 scoped_ptr<cc::OutputSurface> RenderWidgetCompositor::CreateOutputSurface( | 577 scoped_ptr<cc::OutputSurface> RenderWidgetCompositor::CreateOutputSurface( |
577 bool fallback) { | 578 bool fallback) { |
578 return widget_->CreateOutputSurface(fallback); | 579 return widget_->CreateOutputSurface(fallback); |
579 } | 580 } |
580 | 581 |
581 void RenderWidgetCompositor::DidInitializeOutputSurface(bool success) { | 582 void RenderWidgetCompositor::DidInitializeOutputSurface(bool success) { |
582 if (!success) | 583 if (!success) |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
624 widget_->OnSwapBuffersAborted(); | 625 widget_->OnSwapBuffersAborted(); |
625 } | 626 } |
626 | 627 |
627 void RenderWidgetCompositor::RateLimitSharedMainThreadContext() { | 628 void RenderWidgetCompositor::RateLimitSharedMainThreadContext() { |
628 cc::ContextProvider* provider = | 629 cc::ContextProvider* provider = |
629 RenderThreadImpl::current()->SharedMainThreadContextProvider().get(); | 630 RenderThreadImpl::current()->SharedMainThreadContextProvider().get(); |
630 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM(); | 631 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM(); |
631 } | 632 } |
632 | 633 |
633 } // namespace content | 634 } // namespace content |
OLD | NEW |