| 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_RESOURCES_TILE_PRIORITY_H_ | 5 #ifndef CC_RESOURCES_TILE_PRIORITY_H_ |
| 6 #define CC_RESOURCES_TILE_PRIORITY_H_ | 6 #define CC_RESOURCES_TILE_PRIORITY_H_ |
| 7 | 7 |
| 8 #include <algorithm> | 8 #include <algorithm> |
| 9 #include <limits> | 9 #include <limits> |
| 10 | 10 |
| (...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 169 | 169 |
| 170 // Be sure to update TreePriorityAsValue when adding new fields. | 170 // Be sure to update TreePriorityAsValue when adding new fields. |
| 171 }; | 171 }; |
| 172 scoped_ptr<base::Value> TreePriorityAsValue(TreePriority prio); | 172 scoped_ptr<base::Value> TreePriorityAsValue(TreePriority prio); |
| 173 | 173 |
| 174 class GlobalStateThatImpactsTilePriority { | 174 class GlobalStateThatImpactsTilePriority { |
| 175 public: | 175 public: |
| 176 GlobalStateThatImpactsTilePriority() | 176 GlobalStateThatImpactsTilePriority() |
| 177 : memory_limit_policy(ALLOW_NOTHING) | 177 : memory_limit_policy(ALLOW_NOTHING) |
| 178 , memory_limit_in_bytes(0) | 178 , memory_limit_in_bytes(0) |
| 179 , unused_memory_limit_in_bytes(0) |
| 179 , tree_priority(SAME_PRIORITY_FOR_BOTH_TREES) { | 180 , tree_priority(SAME_PRIORITY_FOR_BOTH_TREES) { |
| 180 } | 181 } |
| 181 | 182 |
| 182 TileMemoryLimitPolicy memory_limit_policy; | 183 TileMemoryLimitPolicy memory_limit_policy; |
| 183 | 184 |
| 184 size_t memory_limit_in_bytes; | 185 size_t memory_limit_in_bytes; |
| 186 size_t unused_memory_limit_in_bytes; |
| 185 | 187 |
| 186 TreePriority tree_priority; | 188 TreePriority tree_priority; |
| 187 | 189 |
| 188 scoped_ptr<base::Value> AsValue() const; | 190 scoped_ptr<base::Value> AsValue() const; |
| 189 }; | 191 }; |
| 190 | 192 |
| 191 } // namespace cc | 193 } // namespace cc |
| 192 | 194 |
| 193 #endif // CC_RESOURCES_TILE_PRIORITY_H_ | 195 #endif // CC_RESOURCES_TILE_PRIORITY_H_ |
| OLD | NEW |