| Index: cc/trees/single_thread_proxy.cc
|
| diff --git a/cc/trees/single_thread_proxy.cc b/cc/trees/single_thread_proxy.cc
|
| index 7469f7cdce241a53d45308a282c6ce92cad5d0e1..cd220c1c37e749df532e2ad8acbceccfe4437760 100644
|
| --- a/cc/trees/single_thread_proxy.cc
|
| +++ b/cc/trees/single_thread_proxy.cc
|
| @@ -425,9 +425,8 @@ void SingleThreadProxy::OnDrawForCompositorFrameSink(
|
| }
|
|
|
| void SingleThreadProxy::NeedsImplSideInvalidation() {
|
| - // TODO(khushalsagar): Plumb this to the scheduler when
|
| - // https://codereview.chromium.org/2659123004/ lands. See crbug.com/686267.
|
| - NOTIMPLEMENTED();
|
| + DCHECK(scheduler_on_impl_thread_);
|
| + scheduler_on_impl_thread_->SetNeedsImplSideInvalidation();
|
| }
|
|
|
| void SingleThreadProxy::CompositeImmediately(base::TimeTicks frame_begin_time) {
|
| @@ -604,6 +603,7 @@ void SingleThreadProxy::ScheduledActionSendBeginMainFrame(
|
| task_runner_provider_->MainThreadTaskRunner()->PostTask(
|
| FROM_HERE, base::Bind(&SingleThreadProxy::BeginMainFrame,
|
| weak_factory_.GetWeakPtr(), begin_frame_args));
|
| + layer_tree_host_impl_->DidSendBeginMainFrame();
|
| }
|
|
|
| void SingleThreadProxy::SendBeginMainFrameNotExpectedSoon() {
|
| @@ -732,7 +732,19 @@ void SingleThreadProxy::ScheduledActionInvalidateCompositorFrameSink() {
|
| }
|
|
|
| void SingleThreadProxy::ScheduledActionPerformImplSideInvalidation() {
|
| - NOTIMPLEMENTED();
|
| + DCHECK(scheduler_on_impl_thread_);
|
| +
|
| + DebugScopedSetImplThread impl(task_runner_provider_);
|
| + commit_blocking_task_runner_.reset(new BlockingTaskRunner::CapturePostTasks(
|
| + task_runner_provider_->blocking_main_thread_task_runner()));
|
| + layer_tree_host_impl_->InvalidateContentOnImplSide();
|
| +
|
| + // Invalidations go directly to the active tree, so we synchronously call
|
| + // NotifyReadyToActivate to update the scheduler and LTHI state correctly.
|
| + // Since in single-threaded mode the scheduler will wait for a ready to draw
|
| + // signal from LTHI, the draw will remain blocked till the invalidated tiles
|
| + // are ready.
|
| + NotifyReadyToActivate();
|
| }
|
|
|
| void SingleThreadProxy::UpdateBrowserControlsState(
|
|
|