| 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 <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <cmath> | 9 #include <cmath> |
| 10 #include <limits> | 10 #include <limits> |
| (...skipping 1030 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1041 void RenderWidgetCompositor::BeginMainFrame(const cc::BeginFrameArgs& args) { | 1041 void RenderWidgetCompositor::BeginMainFrame(const cc::BeginFrameArgs& args) { |
| 1042 compositor_deps_->GetRendererScheduler()->WillBeginFrame(args); | 1042 compositor_deps_->GetRendererScheduler()->WillBeginFrame(args); |
| 1043 double frame_time_sec = (args.frame_time - base::TimeTicks()).InSecondsF(); | 1043 double frame_time_sec = (args.frame_time - base::TimeTicks()).InSecondsF(); |
| 1044 delegate_->BeginMainFrame(frame_time_sec); | 1044 delegate_->BeginMainFrame(frame_time_sec); |
| 1045 } | 1045 } |
| 1046 | 1046 |
| 1047 void RenderWidgetCompositor::BeginMainFrameNotExpectedSoon() { | 1047 void RenderWidgetCompositor::BeginMainFrameNotExpectedSoon() { |
| 1048 compositor_deps_->GetRendererScheduler()->BeginFrameNotExpectedSoon(); | 1048 compositor_deps_->GetRendererScheduler()->BeginFrameNotExpectedSoon(); |
| 1049 } | 1049 } |
| 1050 | 1050 |
| 1051 void RenderWidgetCompositor::BeginMainFrameNotExpectedUntil( |
| 1052 base::TimeTicks time) { |
| 1053 compositor_deps_->GetRendererScheduler()->BeginMainFrameNotExpectedUntil( |
| 1054 time); |
| 1055 } |
| 1056 |
| 1051 void RenderWidgetCompositor::UpdateLayerTreeHost() { | 1057 void RenderWidgetCompositor::UpdateLayerTreeHost() { |
| 1052 delegate_->UpdateVisualState(); | 1058 delegate_->UpdateVisualState(); |
| 1053 } | 1059 } |
| 1054 | 1060 |
| 1055 void RenderWidgetCompositor::ApplyViewportDeltas( | 1061 void RenderWidgetCompositor::ApplyViewportDeltas( |
| 1056 const gfx::Vector2dF& inner_delta, | 1062 const gfx::Vector2dF& inner_delta, |
| 1057 const gfx::Vector2dF& outer_delta, | 1063 const gfx::Vector2dF& outer_delta, |
| 1058 const gfx::Vector2dF& elastic_overscroll_delta, | 1064 const gfx::Vector2dF& elastic_overscroll_delta, |
| 1059 float page_scale, | 1065 float page_scale, |
| 1060 float top_controls_delta) { | 1066 float top_controls_delta) { |
| (...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1157 void RenderWidgetCompositor::SetContentSourceId(uint32_t id) { | 1163 void RenderWidgetCompositor::SetContentSourceId(uint32_t id) { |
| 1158 layer_tree_host_->SetContentSourceId(id); | 1164 layer_tree_host_->SetContentSourceId(id); |
| 1159 } | 1165 } |
| 1160 | 1166 |
| 1161 void RenderWidgetCompositor::SetLocalSurfaceId( | 1167 void RenderWidgetCompositor::SetLocalSurfaceId( |
| 1162 const cc::LocalSurfaceId& local_surface_id) { | 1168 const cc::LocalSurfaceId& local_surface_id) { |
| 1163 layer_tree_host_->SetLocalSurfaceId(local_surface_id); | 1169 layer_tree_host_->SetLocalSurfaceId(local_surface_id); |
| 1164 } | 1170 } |
| 1165 | 1171 |
| 1166 } // namespace content | 1172 } // namespace content |
| OLD | NEW |