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 #include "base/command_line.h" | 10 #include "base/command_line.h" |
(...skipping 840 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
851 widget_->didCommitAndDrawCompositorFrame(); | 851 widget_->didCommitAndDrawCompositorFrame(); |
852 } | 852 } |
853 | 853 |
854 void RenderWidgetCompositor::DidCompleteSwapBuffers() { | 854 void RenderWidgetCompositor::DidCompleteSwapBuffers() { |
855 widget_->didCompleteSwapBuffers(); | 855 widget_->didCompleteSwapBuffers(); |
856 bool threaded = !!compositor_deps_->GetCompositorImplThreadTaskRunner().get(); | 856 bool threaded = !!compositor_deps_->GetCompositorImplThreadTaskRunner().get(); |
857 if (!threaded) | 857 if (!threaded) |
858 widget_->OnSwapBuffersComplete(); | 858 widget_->OnSwapBuffersComplete(); |
859 } | 859 } |
860 | 860 |
| 861 void RenderWidgetCompositor::DidCompletePageScaleAnimation() { |
| 862 widget_->DidCompletePageScaleAnimation(); |
| 863 } |
| 864 |
861 void RenderWidgetCompositor::ScheduleAnimation() { | 865 void RenderWidgetCompositor::ScheduleAnimation() { |
862 widget_->scheduleAnimation(); | 866 widget_->scheduleAnimation(); |
863 } | 867 } |
864 | 868 |
865 void RenderWidgetCompositor::DidPostSwapBuffers() { | 869 void RenderWidgetCompositor::DidPostSwapBuffers() { |
866 widget_->OnSwapBuffersPosted(); | 870 widget_->OnSwapBuffersPosted(); |
867 } | 871 } |
868 | 872 |
869 void RenderWidgetCompositor::DidAbortSwapBuffers() { | 873 void RenderWidgetCompositor::DidAbortSwapBuffers() { |
870 widget_->OnSwapBuffersAborted(); | 874 widget_->OnSwapBuffersAborted(); |
871 } | 875 } |
872 | 876 |
873 void RenderWidgetCompositor::RateLimitSharedMainThreadContext() { | 877 void RenderWidgetCompositor::RateLimitSharedMainThreadContext() { |
874 cc::ContextProvider* provider = | 878 cc::ContextProvider* provider = |
875 compositor_deps_->GetSharedMainThreadContextProvider(); | 879 compositor_deps_->GetSharedMainThreadContextProvider(); |
876 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM(); | 880 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM(); |
877 } | 881 } |
878 | 882 |
879 } // namespace content | 883 } // namespace content |
OLD | NEW |