| 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 1024 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1035 void RenderWidgetCompositor::BeginMainFrame(const cc::BeginFrameArgs& args) { | 1035 void RenderWidgetCompositor::BeginMainFrame(const cc::BeginFrameArgs& args) { |
| 1036 compositor_deps_->GetRendererScheduler()->WillBeginFrame(args); | 1036 compositor_deps_->GetRendererScheduler()->WillBeginFrame(args); |
| 1037 double frame_time_sec = (args.frame_time - base::TimeTicks()).InSecondsF(); | 1037 double frame_time_sec = (args.frame_time - base::TimeTicks()).InSecondsF(); |
| 1038 delegate_->BeginMainFrame(frame_time_sec); | 1038 delegate_->BeginMainFrame(frame_time_sec); |
| 1039 } | 1039 } |
| 1040 | 1040 |
| 1041 void RenderWidgetCompositor::BeginMainFrameNotExpectedSoon() { | 1041 void RenderWidgetCompositor::BeginMainFrameNotExpectedSoon() { |
| 1042 compositor_deps_->GetRendererScheduler()->BeginFrameNotExpectedSoon(); | 1042 compositor_deps_->GetRendererScheduler()->BeginFrameNotExpectedSoon(); |
| 1043 } | 1043 } |
| 1044 | 1044 |
| 1045 void RenderWidgetCompositor::BeginMainFrameNotExpectedUntil( |
| 1046 base::TimeTicks time) { |
| 1047 compositor_deps_->GetRendererScheduler()->BeginMainFrameNotExpectedUntil( |
| 1048 time); |
| 1049 } |
| 1050 |
| 1045 void RenderWidgetCompositor::UpdateLayerTreeHost() { | 1051 void RenderWidgetCompositor::UpdateLayerTreeHost() { |
| 1046 delegate_->UpdateVisualState(); | 1052 delegate_->UpdateVisualState(); |
| 1047 } | 1053 } |
| 1048 | 1054 |
| 1049 void RenderWidgetCompositor::ApplyViewportDeltas( | 1055 void RenderWidgetCompositor::ApplyViewportDeltas( |
| 1050 const gfx::Vector2dF& inner_delta, | 1056 const gfx::Vector2dF& inner_delta, |
| 1051 const gfx::Vector2dF& outer_delta, | 1057 const gfx::Vector2dF& outer_delta, |
| 1052 const gfx::Vector2dF& elastic_overscroll_delta, | 1058 const gfx::Vector2dF& elastic_overscroll_delta, |
| 1053 float page_scale, | 1059 float page_scale, |
| 1054 float top_controls_delta) { | 1060 float top_controls_delta) { |
| (...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1147 void RenderWidgetCompositor::SetContentSourceId(uint32_t id) { | 1153 void RenderWidgetCompositor::SetContentSourceId(uint32_t id) { |
| 1148 layer_tree_host_->SetContentSourceId(id); | 1154 layer_tree_host_->SetContentSourceId(id); |
| 1149 } | 1155 } |
| 1150 | 1156 |
| 1151 void RenderWidgetCompositor::SetLocalSurfaceId( | 1157 void RenderWidgetCompositor::SetLocalSurfaceId( |
| 1152 const cc::LocalSurfaceId& local_surface_id) { | 1158 const cc::LocalSurfaceId& local_surface_id) { |
| 1153 layer_tree_host_->SetLocalSurfaceId(local_surface_id); | 1159 layer_tree_host_->SetLocalSurfaceId(local_surface_id); |
| 1154 } | 1160 } |
| 1155 | 1161 |
| 1156 } // namespace content | 1162 } // namespace content |
| OLD | NEW |