Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(160)

Side by Side Diff: cc/resources/tile_priority.h

Issue 935333002: Update from https://crrev.com/316786 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « cc/resources/tile_manager_unittest.cc ('k') | cc/resources/tile_priority.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include <string> 10 #include <string>
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 } else if (active.priority_bin > pending.priority_bin) { 67 } else if (active.priority_bin > pending.priority_bin) {
68 priority_bin = pending.priority_bin; 68 priority_bin = pending.priority_bin;
69 distance_to_visible = pending.distance_to_visible; 69 distance_to_visible = pending.distance_to_visible;
70 } else { 70 } else {
71 priority_bin = active.priority_bin; 71 priority_bin = active.priority_bin;
72 distance_to_visible = 72 distance_to_visible =
73 std::min(active.distance_to_visible, pending.distance_to_visible); 73 std::min(active.distance_to_visible, pending.distance_to_visible);
74 } 74 }
75 } 75 }
76 76
77 void AsValueInto(base::debug::TracedValue* dict) const; 77 void AsValueInto(base::trace_event::TracedValue* dict) const;
78 78
79 bool operator ==(const TilePriority& other) const { 79 bool operator ==(const TilePriority& other) const {
80 return resolution == other.resolution && 80 return resolution == other.resolution &&
81 priority_bin == other.priority_bin && 81 priority_bin == other.priority_bin &&
82 distance_to_visible == other.distance_to_visible; 82 distance_to_visible == other.distance_to_visible;
83 } 83 }
84 84
85 bool operator !=(const TilePriority& other) const { 85 bool operator !=(const TilePriority& other) const {
86 return !(*this == other); 86 return !(*this == other);
87 } 87 }
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 return memory_limit_policy == other.memory_limit_policy && 144 return memory_limit_policy == other.memory_limit_policy &&
145 soft_memory_limit_in_bytes == other.soft_memory_limit_in_bytes && 145 soft_memory_limit_in_bytes == other.soft_memory_limit_in_bytes &&
146 hard_memory_limit_in_bytes == other.hard_memory_limit_in_bytes && 146 hard_memory_limit_in_bytes == other.hard_memory_limit_in_bytes &&
147 num_resources_limit == other.num_resources_limit && 147 num_resources_limit == other.num_resources_limit &&
148 tree_priority == other.tree_priority; 148 tree_priority == other.tree_priority;
149 } 149 }
150 bool operator!=(const GlobalStateThatImpactsTilePriority& other) const { 150 bool operator!=(const GlobalStateThatImpactsTilePriority& other) const {
151 return !(*this == other); 151 return !(*this == other);
152 } 152 }
153 153
154 void AsValueInto(base::debug::TracedValue* dict) const; 154 void AsValueInto(base::trace_event::TracedValue* dict) const;
155 }; 155 };
156 156
157 } // namespace cc 157 } // namespace cc
158 158
159 #endif // CC_RESOURCES_TILE_PRIORITY_H_ 159 #endif // CC_RESOURCES_TILE_PRIORITY_H_
OLDNEW
« no previous file with comments | « cc/resources/tile_manager_unittest.cc ('k') | cc/resources/tile_priority.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698