| Index: cc/tree_synchronizer.cc
|
| diff --git a/cc/tree_synchronizer.cc b/cc/tree_synchronizer.cc
|
| index 8dd94d14ace1e0926fa516bd6438888b7c011c38..17f62002f018a793be85e496526c8c4a28d7b98e 100644
|
| --- a/cc/tree_synchronizer.cc
|
| +++ b/cc/tree_synchronizer.cc
|
| @@ -62,6 +62,10 @@ scoped_ptr<LayerImpl> TreeSynchronizer::synchronizeTreeRecursive(RawPtrLayerImpl
|
|
|
| scoped_ptr<LayerImpl> layerImpl = reuseOrCreateLayerImpl(newLayers, oldLayers, layer);
|
|
|
| + // This call is not strictly necessary, but it prevents an extra tree
|
| + // recursion to set the host after synchronization in setRootLayer.
|
| + layerImpl->setLayerTreeHostImpl(hostImpl);
|
| +
|
| layerImpl->clearChildList();
|
| const std::vector<scoped_refptr<Layer> >& children = layer->children();
|
| for (size_t i = 0; i < children.size(); ++i)
|
| @@ -71,7 +75,6 @@ scoped_ptr<LayerImpl> TreeSynchronizer::synchronizeTreeRecursive(RawPtrLayerImpl
|
| layerImpl->setReplicaLayer(synchronizeTreeRecursive(newLayers, oldLayers, layer->replicaLayer(), hostImpl));
|
|
|
| layer->pushPropertiesTo(layerImpl.get());
|
| - layerImpl->setLayerTreeHostImpl(hostImpl);
|
|
|
| // Remove all dangling pointers. The pointers will be setup later in updateScrollbarLayerPointersRecursive phase
|
| if (ScrollbarAnimationController* scrollbarController = layerImpl->scrollbarAnimationController()) {
|
|
|