| OLD | NEW |
| 1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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 "cc/trees/layer_tree_host.h" | 5 #include "cc/trees/layer_tree_host.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <algorithm> | 10 #include <algorithm> |
| (...skipping 346 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 357 | 357 |
| 358 // Proxy must be destroyed before the Task Runner Provider. | 358 // Proxy must be destroyed before the Task Runner Provider. |
| 359 proxy_ = nullptr; | 359 proxy_ = nullptr; |
| 360 } | 360 } |
| 361 | 361 |
| 362 // We must clear any pointers into the layer tree prior to destroying it. | 362 // We must clear any pointers into the layer tree prior to destroying it. |
| 363 RegisterViewportLayers(NULL, NULL, NULL, NULL); | 363 RegisterViewportLayers(NULL, NULL, NULL, NULL); |
| 364 | 364 |
| 365 if (root_layer_.get()) { | 365 if (root_layer_.get()) { |
| 366 // The layer tree must be destroyed before the layer tree host. We've | 366 // The layer tree must be destroyed before the layer tree host. We've |
| 367 // made a contract with our animation controllers that the registrar | 367 // made a contract with our animation controllers that the animation_host |
| 368 // will outlive them, and we must make good. | 368 // will outlive them, and we must make good. |
| 369 root_layer_ = NULL; | 369 root_layer_ = NULL; |
| 370 } | 370 } |
| 371 } | 371 } |
| 372 | 372 |
| 373 void LayerTreeHost::WillBeginMainFrame() { | 373 void LayerTreeHost::WillBeginMainFrame() { |
| 374 devtools_instrumentation::WillBeginMainThreadFrame(id(), | 374 devtools_instrumentation::WillBeginMainThreadFrame(id(), |
| 375 source_frame_number()); | 375 source_frame_number()); |
| 376 client_->WillBeginMainFrame(); | 376 client_->WillBeginMainFrame(); |
| 377 } | 377 } |
| (...skipping 1259 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1637 [seq_num](Layer* layer) { | 1637 [seq_num](Layer* layer) { |
| 1638 layer->set_property_tree_sequence_number(seq_num); | 1638 layer->set_property_tree_sequence_number(seq_num); |
| 1639 }, | 1639 }, |
| 1640 CallFunctionLayerType::ALL_LAYERS); | 1640 CallFunctionLayerType::ALL_LAYERS); |
| 1641 | 1641 |
| 1642 surface_id_namespace_ = proto.surface_id_namespace(); | 1642 surface_id_namespace_ = proto.surface_id_namespace(); |
| 1643 next_surface_sequence_ = proto.next_surface_sequence(); | 1643 next_surface_sequence_ = proto.next_surface_sequence(); |
| 1644 } | 1644 } |
| 1645 | 1645 |
| 1646 } // namespace cc | 1646 } // namespace cc |
| OLD | NEW |