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

Side by Side Diff: Source/platform/graphics/paint/DisplayItem.cpp

Issue 1313223002: Simplify subtree (now subsequence) caching (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 3 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "config.h" 5 #include "config.h"
6 #include "platform/graphics/paint/DisplayItem.h" 6 #include "platform/graphics/paint/DisplayItem.h"
7 7
8 namespace blink { 8 namespace blink {
9 9
10 struct SameSizeAsDisplayItem { 10 struct SameSizeAsDisplayItem {
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after
173 173
174 PAINT_PHASE_BASED_DEBUG_STRINGS(Scroll); 174 PAINT_PHASE_BASED_DEBUG_STRINGS(Scroll);
175 if (isEndScrollType(type)) 175 if (isEndScrollType(type))
176 return "End" + typeAsDebugString(endScrollTypeToScrollType(type)); 176 return "End" + typeAsDebugString(endScrollTypeToScrollType(type));
177 177
178 if (isTransform3DType(type)) 178 if (isTransform3DType(type))
179 return transform3DTypeAsDebugString(type); 179 return transform3DTypeAsDebugString(type);
180 if (isEndTransform3DType(type)) 180 if (isEndTransform3DType(type))
181 return "End" + transform3DTypeAsDebugString(endTransform3DTypeToTransfor m3DType(type)); 181 return "End" + transform3DTypeAsDebugString(endTransform3DTypeToTransfor m3DType(type));
182 182
183 PAINT_PHASE_BASED_DEBUG_STRINGS(CachedSubtree);
184 PAINT_PHASE_BASED_DEBUG_STRINGS(BeginSubtree);
185 PAINT_PHASE_BASED_DEBUG_STRINGS(EndSubtree);
186
187 if (type == UninitializedType)
188 return "UninitializedType";
189
190 switch (type) { 183 switch (type) {
191 DEBUG_STRING_CASE(BeginFilter); 184 DEBUG_STRING_CASE(BeginFilter);
192 DEBUG_STRING_CASE(EndFilter); 185 DEBUG_STRING_CASE(EndFilter);
193 DEBUG_STRING_CASE(BeginCompositing); 186 DEBUG_STRING_CASE(BeginCompositing);
194 DEBUG_STRING_CASE(EndCompositing); 187 DEBUG_STRING_CASE(EndCompositing);
195 DEBUG_STRING_CASE(BeginTransform); 188 DEBUG_STRING_CASE(BeginTransform);
196 DEBUG_STRING_CASE(EndTransform); 189 DEBUG_STRING_CASE(EndTransform);
197 DEBUG_STRING_CASE(BeginClipPath); 190 DEBUG_STRING_CASE(BeginClipPath);
198 DEBUG_STRING_CASE(EndClipPath); 191 DEBUG_STRING_CASE(EndClipPath);
199 DEBUG_STRING_CASE(BeginFixedPosition); 192 DEBUG_STRING_CASE(BeginFixedPosition);
200 DEBUG_STRING_CASE(EndFixedPosition); 193 DEBUG_STRING_CASE(EndFixedPosition);
201 DEBUG_STRING_CASE(BeginFixedPositionContainer); 194 DEBUG_STRING_CASE(BeginFixedPositionContainer);
202 DEBUG_STRING_CASE(EndFixedPositionContainer); 195 DEBUG_STRING_CASE(EndFixedPositionContainer);
196 DEBUG_STRING_CASE(BeginSubsequence);
197 DEBUG_STRING_CASE(EndSubsequence);
198 DEBUG_STRING_CASE(CachedSubsequence);
199 DEBUG_STRING_CASE(UninitializedType);
203 DEFAULT_CASE; 200 DEFAULT_CASE;
204 } 201 }
205 } 202 }
206 203
207 WTF::String DisplayItem::asDebugString() const 204 WTF::String DisplayItem::asDebugString() const
208 { 205 {
209 if (!isValid()) 206 if (!isValid())
210 return "null"; 207 return "null";
211 WTF::StringBuilder stringBuilder; 208 WTF::StringBuilder stringBuilder;
212 stringBuilder.append('{'); 209 stringBuilder.append('{');
(...skipping 15 matching lines...) Expand all
228 stringBuilder.append('"'); 225 stringBuilder.append('"');
229 if (m_skippedCache) 226 if (m_skippedCache)
230 stringBuilder.append(", skippedCache: true"); 227 stringBuilder.append(", skippedCache: true");
231 if (m_scope) 228 if (m_scope)
232 stringBuilder.append(String::format(", scope: %d", m_scope)); 229 stringBuilder.append(String::format(", scope: %d", m_scope));
233 } 230 }
234 231
235 #endif 232 #endif
236 233
237 } // namespace blink 234 } // namespace blink
OLDNEW
« no previous file with comments | « Source/platform/graphics/paint/DisplayItem.h ('k') | Source/platform/graphics/paint/DisplayItemList.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698