| Index: cc/trees/layer_tree_host_impl.cc
|
| diff --git a/cc/trees/layer_tree_host_impl.cc b/cc/trees/layer_tree_host_impl.cc
|
| index 1b1f6fc89852be3bb0a5e44a6e868b08b329ea2c..886c38f70b66525136468376fadbe9f59737615f 100644
|
| --- a/cc/trees/layer_tree_host_impl.cc
|
| +++ b/cc/trees/layer_tree_host_impl.cc
|
| @@ -1642,7 +1642,12 @@ bool LayerTreeHostImpl::SwapBuffers(const LayerTreeHostImpl::FrameData& frame) {
|
| void LayerTreeHostImpl::WillBeginImplFrame(const BeginFrameArgs& args) {
|
| // Sample the frame time now. This time will be used for updating animations
|
| // when we draw.
|
| - UpdateCurrentBeginFrameArgs(args);
|
| + DCHECK(!current_begin_frame_args_.IsValid());
|
| + current_begin_frame_args_ = args;
|
| + // TODO(mithro): Stop overriding the frame time once the usage of frame
|
| + // timing is unified.
|
| + current_begin_frame_args_.frame_time = gfx::FrameTime::Now();
|
| +
|
| // Cache the begin impl frame interval
|
| begin_impl_frame_interval_ = args.interval;
|
|
|
| @@ -1657,6 +1662,11 @@ void LayerTreeHostImpl::WillBeginImplFrame(const BeginFrameArgs& args) {
|
| it->OnBeginFrame(args);
|
| }
|
|
|
| +void LayerTreeHostImpl::DidBeginImplFrameDeadline() {
|
| + DCHECK(current_begin_frame_args_.IsValid());
|
| + current_begin_frame_args_ = BeginFrameArgs();
|
| +}
|
| +
|
| void LayerTreeHostImpl::UpdateViewportContainerSizes() {
|
| LayerImpl* inner_container = active_tree_->InnerViewportContainerLayer();
|
| LayerImpl* outer_container = active_tree_->OuterViewportContainerLayer();
|
| @@ -3101,19 +3111,6 @@ TreePriority LayerTreeHostImpl::GetTreePriority() const {
|
| return global_tile_state_.tree_priority;
|
| }
|
|
|
| -void LayerTreeHostImpl::UpdateCurrentBeginFrameArgs(
|
| - const BeginFrameArgs& args) {
|
| - DCHECK(!current_begin_frame_args_.IsValid());
|
| - current_begin_frame_args_ = args;
|
| - // TODO(skyostil): Stop overriding the frame time once the usage of frame
|
| - // timing is unified.
|
| - current_begin_frame_args_.frame_time = gfx::FrameTime::Now();
|
| -}
|
| -
|
| -void LayerTreeHostImpl::ResetCurrentBeginFrameArgsForNextFrame() {
|
| - current_begin_frame_args_ = BeginFrameArgs();
|
| -}
|
| -
|
| BeginFrameArgs LayerTreeHostImpl::CurrentBeginFrameArgs() const {
|
| // Try to use the current frame time to keep animations non-jittery. But if
|
| // we're not in a frame (because this is during an input event or a delayed
|
|
|