Chromium Code Reviews| Index: cc/trees/layer_tree_host.cc |
| diff --git a/cc/trees/layer_tree_host.cc b/cc/trees/layer_tree_host.cc |
| index 6f995d8ca634a3548bb4b460896fd6dc2d806d69..0ee5384a0f68d4bc4063179f9a636ca15a4d5852 100644 |
| --- a/cc/trees/layer_tree_host.cc |
| +++ b/cc/trees/layer_tree_host.cc |
| @@ -383,8 +383,12 @@ void LayerTreeHost::CommitComplete() { |
| client_->DidCommit(); |
| } |
| -scoped_ptr<OutputSurface> LayerTreeHost::CreateOutputSurface() { |
| - return client_->CreateOutputSurface(num_failed_recreate_attempts_ >= 4); |
| +void LayerTreeHost::SetOutputSurface(scoped_ptr<OutputSurface> surface) { |
| + proxy_->SetOutputSurface(surface.Pass()); |
| +} |
| + |
| +void LayerTreeHost::RequestNewOutputSurface() { |
| + client_->RequestNewOutputSurface(num_failed_recreate_attempts_ >= 4); |
| } |
| scoped_ptr<LayerTreeHostImpl> LayerTreeHost::CreateLayerTreeHostImpl( |
| @@ -678,11 +682,10 @@ void LayerTreeHost::Composite(base::TimeTicks frame_begin_time) { |
| SingleThreadProxy* proxy = static_cast<SingleThreadProxy*>(proxy_.get()); |
| SetLayerTreeHostClientReady(); |
| - |
| - if (output_surface_lost_) |
| - proxy->CreateAndInitializeOutputSurface(); |
| - if (output_surface_lost_) |
| + if (output_surface_lost_) { |
| + RequestNewOutputSurface(); |
| return; |
| + } |
|
danakj
2014/06/25 17:43:09
This is a change of behaviour where if they synchr
enne (OOO)
2014/06/25 21:25:05
I'll change that back and add a comment. It shoul
|
| proxy->CompositeImmediately(frame_begin_time); |
| } |