| 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 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 98 for (int i = 0; i < layer_update_proto.layers_size(); ++i) { | 98 for (int i = 0; i < layer_update_proto.layers_size(); ++i) { |
| 99 const proto::LayerProperties layer_properties_proto = | 99 const proto::LayerProperties layer_properties_proto = |
| 100 layer_update_proto.layers(i); | 100 layer_update_proto.layers(i); |
| 101 base_layer_properties_size += layer_properties_proto.base().ByteSize(); | 101 base_layer_properties_size += layer_properties_proto.base().ByteSize(); |
| 102 | 102 |
| 103 if (layer_properties_proto.has_picture()) { | 103 if (layer_properties_proto.has_picture()) { |
| 104 const proto::PictureLayerProperties& picture_proto = | 104 const proto::PictureLayerProperties& picture_proto = |
| 105 layer_properties_proto.picture(); | 105 layer_properties_proto.picture(); |
| 106 picture_layer_properties_size += picture_proto.ByteSize(); | 106 picture_layer_properties_size += picture_proto.ByteSize(); |
| 107 | 107 |
| 108 const proto::RecordingSource& recording_source_proto = | |
| 109 picture_proto.recording_source(); | |
| 110 const proto::DisplayItemList& display_list_proto = | 108 const proto::DisplayItemList& display_list_proto = |
| 111 recording_source_proto.display_list(); | 109 picture_proto.display_list(); |
| 112 display_item_list_size += display_list_proto.ByteSize(); | 110 display_item_list_size += display_list_proto.ByteSize(); |
| 113 | 111 |
| 114 for (int j = 0; j < display_list_proto.items_size(); ++j) { | 112 for (int j = 0; j < display_list_proto.items_size(); ++j) { |
| 115 const proto::DisplayItem& display_item = display_list_proto.items(j); | 113 const proto::DisplayItem& display_item = display_list_proto.items(j); |
| 116 if (display_item.type() == proto::DisplayItem::Type_Drawing) | 114 if (display_item.type() == proto::DisplayItem::Type_Drawing) |
| 117 drawing_display_items_size += display_item.ByteSize(); | 115 drawing_display_items_size += display_item.ByteSize(); |
| 118 } | 116 } |
| 119 } | 117 } |
| 120 } | 118 } |
| 121 | 119 |
| (...skipping 1549 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1671 | 1669 |
| 1672 surface_client_id_ = proto.surface_client_id(); | 1670 surface_client_id_ = proto.surface_client_id(); |
| 1673 next_surface_sequence_ = proto.next_surface_sequence(); | 1671 next_surface_sequence_ = proto.next_surface_sequence(); |
| 1674 } | 1672 } |
| 1675 | 1673 |
| 1676 AnimationHost* LayerTreeHost::animation_host() const { | 1674 AnimationHost* LayerTreeHost::animation_host() const { |
| 1677 return layer_tree_.animation_host(); | 1675 return layer_tree_.animation_host(); |
| 1678 } | 1676 } |
| 1679 | 1677 |
| 1680 } // namespace cc | 1678 } // namespace cc |
| OLD | NEW |