| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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 #ifndef CC_TREES_LAYER_TREE_IMPL_H_ | 5 #ifndef CC_TREES_LAYER_TREE_IMPL_H_ |
| 6 #define CC_TREES_LAYER_TREE_IMPL_H_ | 6 #define CC_TREES_LAYER_TREE_IMPL_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| 11 #include "base/containers/hash_tables.h" | 11 #include "base/containers/hash_tables.h" |
| 12 #include "base/values.h" | 12 #include "base/values.h" |
| 13 #include "cc/layers/layer_impl.h" | 13 #include "cc/layers/layer_impl.h" |
| 14 #include "cc/resources/ui_resource_manager_client.h" |
| 14 #include "ui/base/latency_info.h" | 15 #include "ui/base/latency_info.h" |
| 15 | 16 |
| 16 #if defined(COMPILER_GCC) | 17 #if defined(COMPILER_GCC) |
| 17 namespace BASE_HASH_NAMESPACE { | 18 namespace BASE_HASH_NAMESPACE { |
| 18 template<> | 19 template<> |
| 19 struct hash<cc::LayerImpl*> { | 20 struct hash<cc::LayerImpl*> { |
| 20 size_t operator()(cc::LayerImpl* ptr) const { | 21 size_t operator()(cc::LayerImpl* ptr) const { |
| 21 return hash<size_t>()(reinterpret_cast<size_t>(ptr)); | 22 return hash<size_t>()(reinterpret_cast<size_t>(ptr)); |
| 22 } | 23 } |
| 23 }; | 24 }; |
| (...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 183 | 184 |
| 184 void SetRootLayerScrollOffsetDelegate( | 185 void SetRootLayerScrollOffsetDelegate( |
| 185 LayerScrollOffsetDelegate* root_layer_scroll_offset_delegate); | 186 LayerScrollOffsetDelegate* root_layer_scroll_offset_delegate); |
| 186 | 187 |
| 187 void SetLatencyInfo(const ui::LatencyInfo& latency_info); | 188 void SetLatencyInfo(const ui::LatencyInfo& latency_info); |
| 188 const ui::LatencyInfo& GetLatencyInfo(); | 189 const ui::LatencyInfo& GetLatencyInfo(); |
| 189 void ClearLatencyInfo(); | 190 void ClearLatencyInfo(); |
| 190 | 191 |
| 191 void WillModifyTilePriorities(); | 192 void WillModifyTilePriorities(); |
| 192 | 193 |
| 194 ResourceProvider::ResourceId ResourceIdForUIResource(UIResourceId uid) const; |
| 195 |
| 193 void AddLayerWithCopyOutputRequest(LayerImpl* layer); | 196 void AddLayerWithCopyOutputRequest(LayerImpl* layer); |
| 194 void RemoveLayerWithCopyOutputRequest(LayerImpl* layer); | 197 void RemoveLayerWithCopyOutputRequest(LayerImpl* layer); |
| 195 const std::vector<LayerImpl*> LayersWithCopyOutputRequest() const; | 198 const std::vector<LayerImpl*> LayersWithCopyOutputRequest() const; |
| 196 | 199 |
| 197 protected: | 200 protected: |
| 198 explicit LayerTreeImpl(LayerTreeHostImpl* layer_tree_host_impl); | 201 explicit LayerTreeImpl(LayerTreeHostImpl* layer_tree_host_impl); |
| 199 | 202 |
| 200 void UpdateSolidColorScrollbars(); | 203 void UpdateSolidColorScrollbars(); |
| 201 | 204 |
| 202 void UpdateRootScrollLayerSizeDelta(); | 205 void UpdateRootScrollLayerSizeDelta(); |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 239 | 242 |
| 240 ui::LatencyInfo latency_info_; | 243 ui::LatencyInfo latency_info_; |
| 241 | 244 |
| 242 private: | 245 private: |
| 243 DISALLOW_COPY_AND_ASSIGN(LayerTreeImpl); | 246 DISALLOW_COPY_AND_ASSIGN(LayerTreeImpl); |
| 244 }; | 247 }; |
| 245 | 248 |
| 246 } // namespace cc | 249 } // namespace cc |
| 247 | 250 |
| 248 #endif // CC_TREES_LAYER_TREE_IMPL_H_ | 251 #endif // CC_TREES_LAYER_TREE_IMPL_H_ |
| OLD | NEW |