| 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 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 127 | 127 |
| 128 // NOTE: Be sure to update TreePriorityAsValue and kBinPolicyMap when adding | 128 // NOTE: Be sure to update TreePriorityAsValue and kBinPolicyMap when adding |
| 129 // or reordering fields. | 129 // or reordering fields. |
| 130 }; | 130 }; |
| 131 scoped_ptr<base::Value> TileMemoryLimitPolicyAsValue( | 131 scoped_ptr<base::Value> TileMemoryLimitPolicyAsValue( |
| 132 TileMemoryLimitPolicy policy); | 132 TileMemoryLimitPolicy policy); |
| 133 | 133 |
| 134 enum TreePriority { | 134 enum TreePriority { |
| 135 SAME_PRIORITY_FOR_BOTH_TREES, | 135 SAME_PRIORITY_FOR_BOTH_TREES, |
| 136 SMOOTHNESS_TAKES_PRIORITY, | 136 SMOOTHNESS_TAKES_PRIORITY, |
| 137 NEW_CONTENT_TAKES_PRIORITY | 137 NEW_CONTENT_TAKES_PRIORITY, |
| 138 | 138 NUM_TREE_PRIORITIES |
| 139 // Be sure to update TreePriorityAsValue when adding new fields. | 139 // Be sure to update TreePriorityAsValue when adding new fields. |
| 140 }; | 140 }; |
| 141 scoped_ptr<base::Value> TreePriorityAsValue(TreePriority prio); | 141 scoped_ptr<base::Value> TreePriorityAsValue(TreePriority prio); |
| 142 | 142 |
| 143 class GlobalStateThatImpactsTilePriority { | 143 class GlobalStateThatImpactsTilePriority { |
| 144 public: | 144 public: |
| 145 GlobalStateThatImpactsTilePriority() | 145 GlobalStateThatImpactsTilePriority() |
| 146 : memory_limit_policy(ALLOW_NOTHING), | 146 : memory_limit_policy(ALLOW_NOTHING), |
| 147 soft_memory_limit_in_bytes(0), | 147 soft_memory_limit_in_bytes(0), |
| 148 hard_memory_limit_in_bytes(0), | 148 hard_memory_limit_in_bytes(0), |
| (...skipping 18 matching lines...) Expand all Loading... |
| 167 bool operator!=(const GlobalStateThatImpactsTilePriority& other) const { | 167 bool operator!=(const GlobalStateThatImpactsTilePriority& other) const { |
| 168 return !(*this == other); | 168 return !(*this == other); |
| 169 } | 169 } |
| 170 | 170 |
| 171 scoped_ptr<base::Value> AsValue() const; | 171 scoped_ptr<base::Value> AsValue() const; |
| 172 }; | 172 }; |
| 173 | 173 |
| 174 } // namespace cc | 174 } // namespace cc |
| 175 | 175 |
| 176 #endif // CC_RESOURCES_TILE_PRIORITY_H_ | 176 #endif // CC_RESOURCES_TILE_PRIORITY_H_ |
| OLD | NEW |