| 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 571 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 582 } | 582 } |
| 583 | 583 |
| 584 void RenderWidgetCompositor::setShowScrollBottleneckRects(bool show) { | 584 void RenderWidgetCompositor::setShowScrollBottleneckRects(bool show) { |
| 585 cc::LayerTreeDebugState debug_state = layer_tree_host_->debug_state(); | 585 cc::LayerTreeDebugState debug_state = layer_tree_host_->debug_state(); |
| 586 debug_state.show_touch_event_handler_rects = show; | 586 debug_state.show_touch_event_handler_rects = show; |
| 587 debug_state.show_wheel_event_handler_rects = show; | 587 debug_state.show_wheel_event_handler_rects = show; |
| 588 debug_state.show_non_fast_scrollable_rects = show; | 588 debug_state.show_non_fast_scrollable_rects = show; |
| 589 layer_tree_host_->SetDebugState(debug_state); | 589 layer_tree_host_->SetDebugState(debug_state); |
| 590 } | 590 } |
| 591 | 591 |
| 592 void RenderWidgetCompositor::WillBeginMainFrame() { | 592 void RenderWidgetCompositor::WillBeginMainFrame(int frame_id) { |
| 593 widget_->InstrumentWillBeginFrame(); | 593 widget_->InstrumentWillBeginFrame(frame_id); |
| 594 widget_->willBeginCompositorFrame(); | 594 widget_->willBeginCompositorFrame(); |
| 595 } | 595 } |
| 596 | 596 |
| 597 void RenderWidgetCompositor::DidBeginMainFrame() { | 597 void RenderWidgetCompositor::DidBeginMainFrame() { |
| 598 widget_->InstrumentDidBeginFrame(); | 598 widget_->InstrumentDidBeginFrame(); |
| 599 } | 599 } |
| 600 | 600 |
| 601 void RenderWidgetCompositor::Animate(double frame_begin_time) { | 601 void RenderWidgetCompositor::Animate(double frame_begin_time) { |
| 602 widget_->webwidget()->animate(frame_begin_time); | 602 widget_->webwidget()->animate(frame_begin_time); |
| 603 } | 603 } |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 648 return RenderThreadImpl::current()->OffscreenCompositorContextProvider(); | 648 return RenderThreadImpl::current()->OffscreenCompositorContextProvider(); |
| 649 } | 649 } |
| 650 | 650 |
| 651 void RenderWidgetCompositor::RateLimitSharedMainThreadContext() { | 651 void RenderWidgetCompositor::RateLimitSharedMainThreadContext() { |
| 652 cc::ContextProvider* provider = | 652 cc::ContextProvider* provider = |
| 653 RenderThreadImpl::current()->SharedMainThreadContextProvider().get(); | 653 RenderThreadImpl::current()->SharedMainThreadContextProvider().get(); |
| 654 provider->Context3d()->rateLimitOffscreenContextCHROMIUM(); | 654 provider->Context3d()->rateLimitOffscreenContextCHROMIUM(); |
| 655 } | 655 } |
| 656 | 656 |
| 657 } // namespace content | 657 } // namespace content |
| OLD | NEW |