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

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

Issue 794323004: Emit dummy display item when recorded picture is empty (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase Created 6 years 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 #ifndef NDEBUG 10 #ifndef NDEBUG
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 { 67 {
68 WTF::StringBuilder stringBuilder; 68 WTF::StringBuilder stringBuilder;
69 stringBuilder.append('{'); 69 stringBuilder.append('{');
70 dumpPropertiesAsDebugString(stringBuilder); 70 dumpPropertiesAsDebugString(stringBuilder);
71 stringBuilder.append('}'); 71 stringBuilder.append('}');
72 return stringBuilder.toString(); 72 return stringBuilder.toString();
73 } 73 }
74 74
75 void DisplayItem::dumpPropertiesAsDebugString(WTF::StringBuilder& stringBuilder) const 75 void DisplayItem::dumpPropertiesAsDebugString(WTF::StringBuilder& stringBuilder) const
76 { 76 {
77 stringBuilder.append("name: \"");
78 stringBuilder.append(name());
79 stringBuilder.append("\", ");
77 if (!clientDebugString().isEmpty()) { 80 if (!clientDebugString().isEmpty()) {
78 stringBuilder.append(clientDebugString()); 81 stringBuilder.append(clientDebugString());
79 stringBuilder.append(", "); 82 stringBuilder.append(", ");
80 } 83 }
81 stringBuilder.append("type: \""); 84 stringBuilder.append("type: \"");
82 if (isCached())
83 stringBuilder.append("Cached-");
84 stringBuilder.append(typeAsDebugString(type())); 85 stringBuilder.append(typeAsDebugString(type()));
85 stringBuilder.append('"'); 86 stringBuilder.append('"');
86 } 87 }
87 88
88 #endif 89 #endif
89 90
90 } // namespace blink 91 } // namespace blink
OLDNEW
« no previous file with comments | « Source/platform/graphics/paint/DisplayItem.h ('k') | Source/platform/graphics/paint/DrawingDisplayItem.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698