WebKit Bugzilla
Attachment 373698 Details for
Bug 199546
: Layer visualization needs to show more data about the layers
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-199546-20190708205928.patch (text/plain), 30.74 KB, created by
Simon Fraser (smfr)
on 2019-07-08 20:59:30 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Simon Fraser (smfr)
Created:
2019-07-08 20:59:30 PDT
Size:
30.74 KB
patch
obsolete
>Subversion Revision: 247200 >diff --git a/Source/JavaScriptCore/ChangeLog b/Source/JavaScriptCore/ChangeLog >index cebfd627debd4a8d93a786617c89a0550b514696..22ada4f923e1538d5f1a04da64bf4511e8412cc2 100644 >--- a/Source/JavaScriptCore/ChangeLog >+++ b/Source/JavaScriptCore/ChangeLog >@@ -1,3 +1,14 @@ >+2019-07-07 Simon Fraser <simon.fraser@apple.com> >+ >+ Layer visualization needs to show more data about the layers >+ https://bugs.webkit.org/show_bug.cgi?id=199546 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Add more properties to the Layer object. >+ >+ * inspector/protocol/LayerTree.json: >+ > 2019-07-06 Michael Saboff <msaboff@apple.com> > > switch(String) needs to check for exceptions when resolving the string >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index 7b8f6a802ddbb804ed7015c8783704f7158d8d63..6261942bc51ada8f95141a3347f461047659b901 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,20 @@ >+2019-07-07 Simon Fraser <simon.fraser@apple.com> >+ >+ Layer visualization needs to show more data about the layers >+ https://bugs.webkit.org/show_bug.cgi?id=199546 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Collect some data to add to the layer's properties, including whether it's >+ the root, has tiled backing, is a simple container, and is a container for media (image, video, solid color). >+ >+ * inspector/agents/InspectorLayerTreeAgent.cpp: >+ (WebCore::InspectorLayerTreeAgent::buildObjectForLayer): >+ * inspector/agents/InspectorLayerTreeAgent.h: >+ * rendering/RenderLayerBacking.cpp: >+ (WebCore::RenderLayerBacking::backingStoreAttached const): >+ * rendering/RenderLayerBacking.h: >+ > 2019-07-07 Zalan Bujtas <zalan@apple.com> > > [ContentChangeObserver] Difficult to control videos on iqiyi.com as the actions are mouse hover >diff --git a/Source/WebInspectorUI/ChangeLog b/Source/WebInspectorUI/ChangeLog >index 1df39540308c474a657fd4d918c8968189b1f1c8..ab4b32beb157040b9cc48f0ccb52911a35c20804 100644 >--- a/Source/WebInspectorUI/ChangeLog >+++ b/Source/WebInspectorUI/ChangeLog >@@ -1,3 +1,23 @@ >+2019-07-07 Simon Fraser <simon.fraser@apple.com> >+ >+ Layer visualization needs to show more data about the layers >+ https://bugs.webkit.org/show_bug.cgi?id=199546 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Populate the new layer properties. Fix the 3D view to be able to control stroke and fill opacity, >+ and to use different colors for layers with different properties. >+ >+ * UserInterface/Models/Layer.js: >+ (WI.Layer): >+ (WI.Layer.fromPayload): >+ (WI.Layer.prototype.get attributes): >+ * UserInterface/Views/Layers3DContentView.js: >+ (WI.Layers3DContentView.prototype._createLayerGroup): >+ (WI.Layers3DContentView.prototype._createLayerMesh): >+ (WI.Layers3DContentView.prototype._updateLayerGroupSelection): >+ (WI.Layers3DContentView.prototype._colorsForLayer): >+ > 2019-07-06 Nikita Vasilyev <nvasilyev@apple.com> > > Web Inspector: Styles: unbalanced quotes and parenthesis aren't displayed as property closed after editing values >diff --git a/Source/JavaScriptCore/inspector/protocol/LayerTree.json b/Source/JavaScriptCore/inspector/protocol/LayerTree.json >index fd591152850b0167a7e67de94e28aff548f6a6a5..d0e713233e7efe70ebd0dd4b2535f61039dde53a 100644 >--- a/Source/JavaScriptCore/inspector/protocol/LayerTree.json >+++ b/Source/JavaScriptCore/inspector/protocol/LayerTree.json >@@ -34,6 +34,11 @@ > { "name": "paintCount", "type": "integer", "description": "Indicates how many time this layer has painted." }, > { "name": "memory", "type": "integer", "description": "Estimated memory used by this layer." }, > { "name": "compositedBounds", "$ref": "IntRect", "description": "The bounds of the composited layer." }, >+ { "name": "isRoot", "type": "boolean", "optional": true, "description": "True if the layer is the root layer." }, >+ { "name": "isContainerLayer", "type": "boolean", "optional": true, "description": "True for layers that a simple container layers (with no backing store)." }, >+ { "name": "hasTiledBacking", "type": "boolean", "optional": true, "description": "True if the layer is using tiled backing." }, >+ { "name": "hasMediaContents", "type": "boolean", "optional": true, "description": "True if the layer has media contents (solid color/image/video)." }, >+ { "name": "isBackingStoreDetached", "type": "boolean", "optional": true, "description": "True if the layer backing store is detached, which is done to save memory for layers outside the viewport." }, > { "name": "isInShadowTree", "type": "boolean", "optional": true, "description": "Indicates whether this layer is associated with an element hosted in a shadow tree." }, > { "name": "isReflection", "type": "boolean", "optional": true, "description": "Indicates whether this layer was used to provide a reflection for the element." }, > { "name": "isGeneratedContent", "type": "boolean", "optional": true, "description": "Indicates whether the layer is attached to a pseudo element that is CSS generated content." }, >diff --git a/Source/WebCore/inspector/agents/InspectorLayerTreeAgent.cpp b/Source/WebCore/inspector/agents/InspectorLayerTreeAgent.cpp >index e1e082e41ad2d524f57ef10640288761156824b9..6181f71cd92ef12cc749cca1343e5a67693f917f 100644 >--- a/Source/WebCore/inspector/agents/InspectorLayerTreeAgent.cpp >+++ b/Source/WebCore/inspector/agents/InspectorLayerTreeAgent.cpp >@@ -180,6 +180,27 @@ Ref<Inspector::Protocol::LayerTree::Layer> InspectorLayerTreeAgent::buildObjectF > .setPaintCount(backing->graphicsLayer()->repaintCount()) > .release(); > >+ if (renderLayer->isRenderViewLayer()) >+ layerObject->setIsRoot(true); >+ >+ auto compositingType = renderLayer->isComposited() ? renderLayer->backing()->compositingLayerType() : NormalCompositingLayer; >+ switch (compositingType) { >+ case NormalCompositingLayer: >+ break; >+ case TiledCompositingLayer: >+ layerObject->setHasTiledBacking(true); >+ break; >+ case MediaCompositingLayer: >+ layerObject->setHasMediaContents(true); >+ break; >+ case ContainerCompositingLayer: >+ layerObject->setIsContainerLayer(true); >+ break; >+ } >+ >+ if (renderLayer->isComposited() && !renderLayer->backing()->backingStoreAttached()) >+ layerObject->setIsBackingStoreDetached(true); >+ > if (node && node->shadowHost()) > layerObject->setIsInShadowTree(true); > >diff --git a/Source/WebCore/rendering/RenderLayerBacking.cpp b/Source/WebCore/rendering/RenderLayerBacking.cpp >index b2441ac25e83e28dbe776f51c8701bfcc815bd9c..159773cffb5b229e23b5179c7ffebf3d955cf0e4 100644 >--- a/Source/WebCore/rendering/RenderLayerBacking.cpp >+++ b/Source/WebCore/rendering/RenderLayerBacking.cpp >@@ -3391,6 +3391,11 @@ CompositingLayerType RenderLayerBacking::compositingLayerType() const > return ContainerCompositingLayer; > } > >+bool RenderLayerBacking::backingStoreAttached() const >+{ >+ return m_graphicsLayer->backingStoreAttached(); >+} >+ > double RenderLayerBacking::backingStoreMemoryEstimate() const > { > double backingMemory; >diff --git a/Source/WebCore/rendering/RenderLayerBacking.h b/Source/WebCore/rendering/RenderLayerBacking.h >index 3b5dee241713190e8435d006da2b54112a9ebd40..53748e58daeecef8028c6c4cbedbf0dda1659b94 100644 >--- a/Source/WebCore/rendering/RenderLayerBacking.h >+++ b/Source/WebCore/rendering/RenderLayerBacking.h >@@ -267,7 +267,8 @@ public: > > // For informative purposes only. > WEBCORE_EXPORT CompositingLayerType compositingLayerType() const; >- >+ WEBCORE_EXPORT bool backingStoreAttached() const; >+ > GraphicsLayer* layerForHorizontalScrollbar() const { return m_layerForHorizontalScrollbar.get(); } > GraphicsLayer* layerForVerticalScrollbar() const { return m_layerForVerticalScrollbar.get(); } > GraphicsLayer* layerForScrollCorner() const { return m_layerForScrollCorner.get(); } >diff --git a/Source/WebInspectorUI/UserInterface/Models/Layer.js b/Source/WebInspectorUI/UserInterface/Models/Layer.js >index 3f1e94253e2d365e6946a5bcded225347c0c53e7..3c96c8c6e31d05c4410fb010748cf6638191fbde 100644 >--- a/Source/WebInspectorUI/UserInterface/Models/Layer.js >+++ b/Source/WebInspectorUI/UserInterface/Models/Layer.js >@@ -24,26 +24,42 @@ > */ > > WI.Layer = class Layer { >- constructor(layerId, nodeId, bounds, paintCount, memory, compositedBounds, isInShadowTree, isReflection, isGeneratedContent, isAnonymous, pseudoElementId, pseudoElement) >+ constructor(layerId, nodeId, bounds, compositedBounds, paintCount, memory, isRoot, isContainerLayer, hasTiledBacking, hasMediaContents, isBackingStoreDetached, isInShadowTree, isReflection, isGeneratedContent, isAnonymous, pseudoElementId, pseudoElement) > { >+ console.assert(typeof layerId === "string"); >+ console.assert(typeof nodeId === "number"); > console.assert(typeof bounds === "object"); >+ console.assert(typeof compositedBounds === "object"); >+ console.assert(typeof paintCount === "number"); >+ console.assert(typeof memory === "number"); >+ console.assert(isBackingStoreDetached === undefined || typeof isBackingStoreDetached === "boolean"); >+ console.assert(hasMediaContents === undefined || typeof hasMediaContents === "boolean"); >+ console.assert(hasTiledBacking === undefined || typeof hasTiledBacking === "boolean"); >+ console.assert(isContainerLayer === undefined || typeof isContainerLayer === "boolean"); >+ console.assert(isInShadowTree === undefined || typeof isInShadowTree === "boolean"); >+ console.assert(isReflection === undefined || typeof isReflection === "boolean"); >+ console.assert(isGeneratedContent === undefined || typeof isGeneratedContent === "boolean"); >+ console.assert(isAnonymous === undefined || typeof isAnonymous === "boolean"); >+ console.assert(pseudoElementId === undefined || typeof pseudoElementId === "number"); >+ console.assert(pseudoElement === undefined || typeof pseudoElement === "string"); > > this._layerId = layerId; > this._nodeId = nodeId; > this._bounds = bounds; >+ this._compositedBounds = compositedBounds; > this._paintCount = paintCount; > this._memory = memory; >- this._compositedBounds = compositedBounds; >- this._isInShadowTree = isInShadowTree; >- this._isReflection = isReflection; >- this._isGeneratedContent = isGeneratedContent; >- this._isAnonymous = isAnonymous; >- this._pseudoElementId = pseudoElementId; >- this._pseudoElement = pseudoElement; >- >- // FIXME: This should probably be moved to the backend. >- this._compositedBounds.x = this._bounds.x; >- this._compositedBounds.y = this._bounds.y; >+ this._isRoot = !!isRoot; >+ this._isContainerLayer = !!isContainerLayer; >+ this._hasTiledBacking = !!hasTiledBacking; >+ this._hasMediaContents = !!hasMediaContents; >+ this._isBackingStoreDetached = !!isBackingStoreDetached; >+ this._isInShadowTree = !!isInShadowTree; >+ this._isReflection = !!isReflection; >+ this._isGeneratedContent = !!isGeneratedContent; >+ this._isAnonymous = !!isAnonymous; >+ this._pseudoElementId = pseudoElementId || null; >+ this._pseudoElement = pseudoElement || null; > } > > // Static >@@ -54,9 +70,14 @@ WI.Layer = class Layer { > payload.layerId, > payload.nodeId, > payload.bounds, >+ payload.compositedBounds, > payload.paintCount, > payload.memory, >- payload.compositedBounds, >+ payload.isRoot, >+ payload.isContainerLayer, >+ payload.hasTiledBacking, >+ payload.hasMediaContents, >+ payload.isBackingStoreDetached, > payload.isInShadowTree, > payload.isReflection, > payload.isGeneratedContent, >@@ -71,9 +92,14 @@ WI.Layer = class Layer { > get layerId() { return this._layerId; } > get nodeId() { return this._nodeId; } > get bounds() { return this._bounds; } >+ get compositedBounds() { return this._compositedBounds; } > get paintCount() { return this._paintCount; } > get memory() { return this._memory; } >- get compositedBounds() { return this._compositedBounds; } >+ get isRoot() { return this._isRoot; } >+ get isContainerLayer() { return this._isContainerLayer; } >+ get hasTiledBacking() { return this._hasTiledBacking; } >+ get hasMediaContents() { return this._hasMediaContents; } >+ get isBackingStoreDetached() { return this._isBackingStoreDetached; } > get isInShadowTree() { return this._isInShadowTree; } > get isReflection() { return this._isReflection; } > get isGeneratedContent() { return this._isGeneratedContent; } >diff --git a/Source/WebInspectorUI/UserInterface/Views/Layers3DContentView.js b/Source/WebInspectorUI/UserInterface/Views/Layers3DContentView.js >index a53667ac7f4379f90221b1aa631f8a498b6cc5af..49f71aa6a4d4ffd158ea8e0f9a4eb824a2e56db4 100644 >--- a/Source/WebInspectorUI/UserInterface/Views/Layers3DContentView.js >+++ b/Source/WebInspectorUI/UserInterface/Views/Layers3DContentView.js >@@ -274,14 +274,15 @@ WI.Layers3DContentView = class Layers3DContentView extends WI.ContentView > this.dispatchEventToListeners(WI.ContentView.Event.SelectionPathComponentsDidChange); > } > >- _createLayerGroup(layer) { >+ _createLayerGroup(layer) >+ { > let layerGroup = new THREE.Group; > layerGroup.userData.layer = layer; >- layerGroup.add(this._createLayerMesh(layer.bounds), this._createLayerMesh(layer.compositedBounds, true)); >+ layerGroup.add(this._createLayerMesh(layer, layer.bounds), this._createLayerMesh(layer, layer.compositedBounds, true)); > return layerGroup; > } > >- _createLayerMesh({width, height}, isOutline = false) >+ _createLayerMesh(layer, {width, height}, isOutline = false) > { > let geometry = new THREE.Geometry; > geometry.vertices.push( >@@ -290,18 +291,23 @@ WI.Layers3DContentView = class Layers3DContentView extends WI.ContentView > new THREE.Vector3(width, -height, 0), > new THREE.Vector3(width, 0, 0), > ); >- >+ >+ let layerColors = this._colorsForLayer(layer); > if (isOutline) { >- let material = new THREE.LineBasicMaterial({color: WI.Layers3DContentView._layerColor.stroke}); >+ let material = new THREE.LineBasicMaterial({ >+ color: layerColors.stroke, >+ opacity: layerColors.strokeOpacity, >+ transparent: true, >+ }); > return new THREE.LineLoop(geometry, material); > } > > geometry.faces.push(new THREE.Face3(0, 1, 3), new THREE.Face3(1, 2, 3)); > > let material = new THREE.MeshBasicMaterial({ >- color: WI.Layers3DContentView._layerColor.fill, >+ color: layerColors.fill, >+ opacity: layerColors.fillOpacity, > transparent: true, >- opacity: 0.4, > side: THREE.DoubleSide, > depthWrite: false, > }); >@@ -350,19 +356,22 @@ WI.Layers3DContentView = class Layers3DContentView extends WI.ContentView > > _updateLayerGroupSelection(layerGroup) > { >- let setColor = ({fill, stroke}) => { >- let [plane, outline] = this._selectedLayerGroup.children; >- plane.material.color.set(fill); >- outline.material.color.set(stroke); >+ let setColor = (layerGroup, selected) => { >+ let colors = this._colorsForLayer(layerGroup.userData.layer, selected); >+ let [plane, outline] = layerGroup.children; >+ plane.material.color.set(colors.fill); >+ plane.material.opacity = colors.fillOpacity; >+ outline.material.color.set(colors.stroke); >+ outline.material.opacity = colors.strokeOpacity; > }; > > if (this._selectedLayerGroup) >- setColor(WI.Layers3DContentView._layerColor); >+ setColor(this._selectedLayerGroup, false); > > this._selectedLayerGroup = layerGroup; > > if (this._selectedLayerGroup) >- setColor(WI.Layers3DContentView._selectedLayerColor); >+ setColor(this._selectedLayerGroup, true); > } > > _centerOnSelection() >@@ -466,6 +475,70 @@ WI.Layers3DContentView = class Layers3DContentView extends WI.ContentView > }); > } > >+ _colorsForLayer(layer, selected) >+ { >+ if (selected) { >+ return { >+ fill: "hsl(208, 66%, 79%)", >+ stroke: "hsl(202, 57%, 68%)", >+ fillOpacity: 0.4, >+ strokeOpacity: 0.9, >+ }; >+ } >+ >+ if (layer.isRoot) { >+ return { >+ fill: "hsl(0, 0%, 0%)", >+ stroke: "hsl(0, 0%, 0%)", >+ fillOpacity: 0.1, >+ strokeOpacity: 0.5, >+ }; >+ } >+ >+ if (layer.hasMediaContents) { >+ return { >+ fill: "hsl(214, 100%, 43%)", >+ stroke: "hsl(214, 100%, 43%)", >+ fillOpacity: 0.4, >+ strokeOpacity: 0.7, >+ }; >+ } >+ >+ if (layer.isContainerLayer) { >+ return { >+ fill: "hsl(56, 72%, 50%)", >+ stroke: "hsl(56, 72%, 50%)", >+ fillOpacity: 0, >+ strokeOpacity: 0.7, >+ }; >+ } >+ >+ if (layer.isBackingStoreDetached) { >+ return { >+ fill: "hsl(76, 0%, 75%)", >+ stroke: "hsl(79, 0%, 50%)", >+ fillOpacity: 0.3, >+ strokeOpacity: 0.5, >+ }; >+ }; >+ >+ if (layer.hasTiledBacking) { >+ return { >+ fill: "hsl(39, 100%, 50%)", >+ stroke: "hsl(39, 100%, 50%)", >+ fillOpacity: 0.3, >+ strokeOpacity: 0.5, >+ }; >+ } >+ >+ return { >+ fill: "hsl(76, 50%, 75%)", >+ stroke: "hsl(79, 45%, 50%)", >+ fillOpacity: 0.4, >+ strokeOpacity: 0.8, >+ }; >+ } >+ > _updateReasonsList(compositingReasons) > { > this._reasonsListElement.removeChildren(); >@@ -534,16 +607,6 @@ WI.Layers3DContentView = class Layers3DContentView extends WI.ContentView > > WI.Layers3DContentView._zPadding = 3000; > >-WI.Layers3DContentView._layerColor = { >- fill: "hsl(76, 49%, 75%)", >- stroke: "hsl(79, 45%, 50%)" >-}; >- >-WI.Layers3DContentView._selectedLayerColor = { >- fill: "hsl(208, 66%, 79%)", >- stroke: "hsl(202, 57%, 68%)" >-}; >- > WI.Layers3DContentView.Event = { > SelectedLayerChanged: "selected-layer-changed" > }; >diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog >index 668c3504d1983581cb1c990b609259203ce43873..bf7f3ea0bc47bf45528a7a134a08bd464bbad473 100644 >--- a/LayoutTests/ChangeLog >+++ b/LayoutTests/ChangeLog >@@ -1,3 +1,13 @@ >+2019-07-07 Simon Fraser <simon.fraser@apple.com> >+ >+ Layer visualization needs to show more data about the layers >+ https://bugs.webkit.org/show_bug.cgi?id=199546 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * inspector/layers/layers-for-node-expected.txt: >+ * inspector/layers/layers-for-node.html: >+ > 2019-07-07 Zalan Bujtas <zalan@apple.com> > > [ContentChangeObserver] Difficult to control videos on iqiyi.com as the actions are mouse hover >diff --git a/LayoutTests/inspector/layers/layers-for-node-expected.txt b/LayoutTests/inspector/layers/layers-for-node-expected.txt >index 399baca2c99963b919c08ef5aa4b91a8aaa21496..453a6c2feebb5900440b52f163316c556d15926c 100644 >--- a/LayoutTests/inspector/layers/layers-for-node-expected.txt >+++ b/LayoutTests/inspector/layers/layers-for-node-expected.txt >@@ -1,4 +1,4 @@ >- >+texttext > === Enable the LayerTree agent === > > PASS >@@ -28,7 +28,28 @@ PASS > "width": "number", > "height": "number" > }, >- "paintCount": "number" >+ "paintCount": "number", >+ "isRoot": true, >+ "hasTiledBacking": true >+ }, >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 100, >+ "y": 0, >+ "width": 100, >+ "height": 100 >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": 100, >+ "height": 100 >+ }, >+ "paintCount": "number", >+ "isContainerLayer": true > }, > { > "layerId": "string", >@@ -46,7 +67,8 @@ PASS > "width": 50, > "height": 50 > }, >- "paintCount": "number" >+ "paintCount": "number", >+ "hasMediaContents": true > }, > { > "layerId": "string", >@@ -82,7 +104,8 @@ PASS > "width": 100, > "height": 100 > }, >- "paintCount": "number" >+ "paintCount": "number", >+ "hasMediaContents": true > }, > { > "layerId": "string", >@@ -147,7 +170,28 @@ PASS > "width": "number", > "height": "number" > }, >- "paintCount": "number" >+ "paintCount": "number", >+ "isRoot": true, >+ "hasTiledBacking": true >+ }, >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 100, >+ "y": 0, >+ "width": 100, >+ "height": 100 >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": 100, >+ "height": 100 >+ }, >+ "paintCount": "number", >+ "isContainerLayer": true > }, > { > "layerId": "string", >@@ -165,7 +209,8 @@ PASS > "width": 50, > "height": 50 > }, >- "paintCount": "number" >+ "paintCount": "number", >+ "hasMediaContents": true > }, > { > "layerId": "string", >@@ -201,7 +246,8 @@ PASS > "width": 100, > "height": 100 > }, >- "paintCount": "number" >+ "paintCount": "number", >+ "hasMediaContents": true > }, > { > "layerId": "string", >@@ -255,7 +301,8 @@ PASS > "width": 50, > "height": 50 > }, >- "paintCount": "number" >+ "paintCount": "number", >+ "hasMediaContents": true > } > ] > >diff --git a/LayoutTests/inspector/layers/layers-for-node.html b/LayoutTests/inspector/layers/layers-for-node.html >index 53b9e208a9cde3b3d83e6c9af3a2d975fd2e81f1..adffe613c2094b34667191b86d5efabac0ce7d60 100644 >--- a/LayoutTests/inspector/layers/layers-for-node.html >+++ b/LayoutTests/inspector/layers/layers-for-node.html >@@ -197,6 +197,13 @@ window.addEventListener("DOMContentLoaded", function () { > top: 0; > left: 0; > } >+ >+ .container { >+ left: 100px; >+ width: 100px; >+ height: 100px; >+ transform: translateZ(0); >+ } > > .regular { > width: 100px; >@@ -210,12 +217,12 @@ window.addEventListener("DOMContentLoaded", function () { > width: 50px; > height: 50px; > background-color: blue; >- -webkit-transform: translateZ(0); >+ transform: translateZ(0); > } > > .offset { > left: 200px; >- -webkit-transform: translateZ(0); >+ transform: translateZ(0); > } > > </style> >@@ -223,13 +230,14 @@ window.addEventListener("DOMContentLoaded", function () { > <body> > > <div class="regular"></div> >+ <div class="container"></div> > > <div class="composited"> >- <div class="composited"></div> >+ <div class="composited">text</div> > </div> > > <div class="regular offset"> >- <div class="composited"></div> >+ <div class="composited">text</div> > </div> > > </body> >diff --git a/LayoutTests/platform/mac-wk1/inspector/layers/layers-for-node-expected.txt b/LayoutTests/platform/mac-wk1/inspector/layers/layers-for-node-expected.txt >new file mode 100644 >index 0000000000000000000000000000000000000000..2dcf0a74b8abae566a5eaad18615695c098d57a2 >--- /dev/null >+++ b/LayoutTests/platform/mac-wk1/inspector/layers/layers-for-node-expected.txt >@@ -0,0 +1,315 @@ >+texttext >+=== Enable the LayerTree agent === >+ >+PASS >+ >+=== Get the Document === >+ >+PASS >+ >+=== Get the initial layer tree === >+ >+PASS >+ >+[ >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 0, >+ "y": 0, >+ "width": "number", >+ "height": "number" >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": "number", >+ "height": "number" >+ }, >+ "paintCount": "number", >+ "isRoot": true, >+ "isContainerLayer": true >+ }, >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 100, >+ "y": 0, >+ "width": 100, >+ "height": 100 >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": 100, >+ "height": 100 >+ }, >+ "paintCount": "number", >+ "isContainerLayer": true >+ }, >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 25, >+ "y": 25, >+ "width": 50, >+ "height": 50 >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": 50, >+ "height": 50 >+ }, >+ "paintCount": "number", >+ "hasMediaContents": true >+ }, >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 50, >+ "y": 50, >+ "width": 50, >+ "height": 50 >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": 50, >+ "height": 50 >+ }, >+ "paintCount": "number" >+ }, >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 200, >+ "y": 0, >+ "width": 100, >+ "height": 100 >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": 100, >+ "height": 100 >+ }, >+ "paintCount": "number", >+ "hasMediaContents": true >+ }, >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 225, >+ "y": 25, >+ "width": 50, >+ "height": 50 >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": 50, >+ "height": 50 >+ }, >+ "paintCount": "number" >+ }, >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 0, >+ "y": 0, >+ "width": "number", >+ "height": "number" >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": "number", >+ "height": "number" >+ }, >+ "paintCount": "number" >+ } >+] >+ >+=== Message the page to add a new composited layer === >+ >+PASS >+ >+=== Get the modified layer tree === >+ >+PASS >+ >+[ >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 0, >+ "y": 0, >+ "width": "number", >+ "height": "number" >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": "number", >+ "height": "number" >+ }, >+ "paintCount": "number", >+ "isRoot": true, >+ "isContainerLayer": true >+ }, >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 100, >+ "y": 0, >+ "width": 100, >+ "height": 100 >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": 100, >+ "height": 100 >+ }, >+ "paintCount": "number", >+ "isContainerLayer": true >+ }, >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 25, >+ "y": 25, >+ "width": 50, >+ "height": 50 >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": 50, >+ "height": 50 >+ }, >+ "paintCount": "number", >+ "hasMediaContents": true >+ }, >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 50, >+ "y": 50, >+ "width": 50, >+ "height": 50 >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": 50, >+ "height": 50 >+ }, >+ "paintCount": "number" >+ }, >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 200, >+ "y": 0, >+ "width": 100, >+ "height": 100 >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": 100, >+ "height": 100 >+ }, >+ "paintCount": "number", >+ "hasMediaContents": true >+ }, >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 225, >+ "y": 25, >+ "width": 50, >+ "height": 50 >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": 50, >+ "height": 50 >+ }, >+ "paintCount": "number" >+ }, >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 0, >+ "y": 0, >+ "width": "number", >+ "height": "number" >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": "number", >+ "height": "number" >+ }, >+ "paintCount": "number", >+ "hasTiledBacking": true >+ }, >+ { >+ "layerId": "string", >+ "nodeId": "number", >+ "bounds": { >+ "x": 25, >+ "y": 25, >+ "width": 50, >+ "height": 50 >+ }, >+ "memory": "number", >+ "compositedBounds": { >+ "x": 0, >+ "y": 0, >+ "width": 50, >+ "height": 50 >+ }, >+ "paintCount": "number", >+ "hasMediaContents": true >+ } >+] >+ >+=== Get attributes for the newly inserted node === >+ >+PASS >+ >+=== Test complete, all expected conditions met === >+
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
bburg
:
review+
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 199546
:
373606
|
373607
|
373611
|
373612
| 373698