Changeset 109466 in webkit
- Timestamp:
- Mar 1, 2012 4:47:56 PM (12 years ago)
- Location:
- trunk/Source
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r109463 r109466 1 2012-03-01 James Robinson <jamesr@chromium.org> 2 3 [chromium] Rename LayerChromium::name to debugName to be more consistent with other debug properties, make threadsafe 4 https://bugs.webkit.org/show_bug.cgi?id=79723 5 6 Reviewed by Adrienne Walker. 7 8 * platform/graphics/chromium/GraphicsLayerChromium.cpp: 9 (WebCore::GraphicsLayerChromium::updateNames): 10 * platform/graphics/chromium/LayerChromium.cpp: 11 (WebCore::LayerChromium::pushPropertiesTo): 12 (WebCore::LayerChromium::setDebugName): 13 (WebCore): 14 * platform/graphics/chromium/LayerChromium.h: 15 (LayerChromium): 16 * platform/graphics/chromium/cc/CCLayerImpl.cpp: 17 (WebCore::CCLayerImpl::dumpLayer): 18 * platform/graphics/chromium/cc/CCLayerImpl.h: 19 (CCLayerImpl): 20 (WebCore::CCLayerImpl::setDebugName): 21 (WebCore::CCLayerImpl::debugName): 22 * platform/graphics/chromium/cc/CCRenderSurface.cpp: 23 (WebCore::CCRenderSurface::name): 24 1 25 2012-03-01 Adam Barth <abarth@webkit.org> 2 26 -
trunk/Source/WebCore/platform/graphics/chromium/GraphicsLayerChromium.cpp
r109424 r109466 118 118 { 119 119 if (m_layer) 120 m_layer->set Name("Layer for " + m_nameBase);120 m_layer->setDebugName("Layer for " + m_nameBase); 121 121 if (m_transformLayer) 122 m_transformLayer->set Name("TransformLayer for " + m_nameBase);122 m_transformLayer->setDebugName("TransformLayer for " + m_nameBase); 123 123 if (m_contentsLayer) 124 m_contentsLayer->set Name("ContentsLayer for " + m_nameBase);124 m_contentsLayer->setDebugName("ContentsLayer for " + m_nameBase); 125 125 } 126 126 -
trunk/Source/WebCore/platform/graphics/chromium/LayerChromium.cpp
r109424 r109466 486 486 } 487 487 488 void LayerChromium::setName(const String& name)489 {490 m_name = name;491 }492 493 488 void LayerChromium::setNeedsDisplayRect(const FloatRect& dirtyRect) 494 489 { … … 512 507 layer->setDebugBorderColor(m_debugBorderColor); 513 508 layer->setDebugBorderWidth(m_debugBorderWidth); 509 layer->setDebugName(m_debugName.isolatedCopy()); // We have to use isolatedCopy() here to safely pass ownership to another thread. 514 510 layer->setDoubleSided(m_doubleSided); 515 511 layer->setDrawsContent(drawsContent()); … … 526 522 m_nonFastScrollableRegionChanged = false; 527 523 } 528 layer->setName(m_name);529 524 layer->setOpaque(m_opaque); 530 525 layer->setOpacity(m_opacity); … … 567 562 } 568 563 564 void LayerChromium::setDebugName(const String& debugName) 565 { 566 m_debugName = debugName; 567 setNeedsCommit(); 568 } 569 570 569 571 void LayerChromium::setContentsScale(float contentsScale) 570 572 { -
trunk/Source/WebCore/platform/graphics/chromium/LayerChromium.h
r109424 r109466 100 100 bool masksToBounds() const { return m_masksToBounds; } 101 101 102 void setName(const String&);103 const String& name() const { return m_name; }104 105 102 void setMaskLayer(LayerChromium*); 106 103 LayerChromium* maskLayer() const { return m_maskLayer.get(); } … … 175 172 void setDebugBorderColor(const Color&); 176 173 void setDebugBorderWidth(float); 174 void setDebugName(const String&); 177 175 178 176 virtual void pushPropertiesTo(CCLayerImpl*); … … 296 294 Color m_debugBorderColor; 297 295 float m_debugBorderWidth; 296 String m_debugName; 298 297 float m_opacity; 299 298 FilterOperations m_filters; … … 324 323 float m_contentsScale; 325 324 326 String m_name;325 bool m_pageScaleDirty; 327 326 328 327 CCLayerAnimationDelegate* m_layerAnimationDelegate; -
trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerImpl.cpp
r108937 r109466 267 267 { 268 268 writeIndent(ts, indent); 269 ts << layerTypeAsString() << "(" << m_ name << ")\n";269 ts << layerTypeAsString() << "(" << m_debugName << ")\n"; 270 270 dumpLayerProperties(ts, indent+2); 271 271 if (m_replicaLayer) { -
trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerImpl.h
r108937 r109466 136 136 const TransformationMatrix& sublayerTransform() const { return m_sublayerTransform; } 137 137 138 void setName(const String& name) { m_name = name; }139 const String& name() const { return m_name; }140 141 138 // Debug layer border - visual effect only, do not change geometry/clipping/etc. 142 139 void setDebugBorderColor(Color); … … 145 142 float debugBorderWidth() const { return m_debugBorderWidth; } 146 143 bool hasDebugBorders() const; 144 145 // Debug layer name. 146 void setDebugName(const String& debugName) { m_debugName = debugName; } 147 String debugName() const { return m_debugName; } 147 148 148 149 CCRenderSurface* renderSurface() const { return m_renderSurface.get(); } … … 295 296 #endif 296 297 297 String m_name;298 299 298 // Render surface this layer draws into. This is a surface that can belong 300 299 // either to this layer (if m_targetRenderSurface == m_renderSurface) or … … 312 311 float m_debugBorderWidth; 313 312 313 // Debug layer name. 314 String m_debugName; 315 314 316 FilterOperations m_filters; 315 317 -
trunk/Source/WebCore/platform/graphics/chromium/cc/CCRenderSurface.cpp
r108013 r109466 240 240 String CCRenderSurface::name() const 241 241 { 242 return String::format("RenderSurface(id=%i,owner=%s)", m_owningLayer->id(), m_owningLayer-> name().utf8().data());242 return String::format("RenderSurface(id=%i,owner=%s)", m_owningLayer->id(), m_owningLayer->debugName().utf8().data()); 243 243 } 244 244 -
trunk/Source/WebKit/chromium/ChangeLog
r109459 r109466 1 2012-03-01 James Robinson <jamesr@chromium.org> 2 3 [chromium] Rename LayerChromium::name to debugName to be more consistent with other debug properties, make threadsafe 4 https://bugs.webkit.org/show_bug.cgi?id=79723 5 6 Reviewed by Adrienne Walker. 7 8 * tests/LayerChromiumTest.cpp: 9 1 10 2012-03-01 Dale Curtis <dalecurtis@chromium.org> 2 11 -
trunk/Source/WebKit/chromium/tests/LayerChromiumTest.cpp
r108937 r109466 490 490 491 491 // Test properties that should not call needsDisplay and needsCommit when changed. 492 EXECUTE_AND_VERIFY_SET_NEEDS_COMMIT_BEHAVIOR(0, testLayer->setName("Test Layer"));493 492 EXECUTE_AND_VERIFY_SET_NEEDS_COMMIT_BEHAVIOR(0, testLayer->setVisibleLayerRect(IntRect(0, 0, 40, 50))); 494 493 EXECUTE_AND_VERIFY_SET_NEEDS_COMMIT_BEHAVIOR(0, testLayer->setUsesLayerClipping(true)); … … 522 521 EXECUTE_AND_VERIFY_SET_NEEDS_COMMIT_BEHAVIOR(1, testLayer->setTransform(TransformationMatrix(0, 0, 0, 0, 0, 0))); 523 522 EXECUTE_AND_VERIFY_SET_NEEDS_COMMIT_BEHAVIOR(1, testLayer->setDoubleSided(false)); 523 EXECUTE_AND_VERIFY_SET_NEEDS_COMMIT_BEHAVIOR(1, testLayer->setDebugName("Test Layer")); 524 524 525 525 // The above tests should not have caused a change to the needsDisplay flag.
Note: See TracChangeset
for help on using the changeset viewer.