Title: [137979] trunk
- Revision
- 137979
- Author
- [email protected]
- Date
- 2012-12-17 20:33:40 -0800 (Mon, 17 Dec 2012)
Log Message
Web Inspector: need to visually distinguish UA shadow roots
https://bugs.webkit.org/show_bug.cgi?id=104877
Reviewed by Yury Semikhatsky.
Source/WebCore:
Now we have an option to show ShadowRoot in the Inspector. Since the Inspector has displayed UserAgent ShadowRoot and
Author ShadowRoot as the same #shadow-root, a user could not distinguish them.
We would like to show UserAgent ShadowRoot as #webkit-shadow-root.
Test: inspector/shadow-root.html
* inspector/InspectorDOMAgent.cpp:
(WebCore::InspectorDOMAgent::buildObjectForNode): Make nodeName of UserAgent ShadowRoot #webkit-shadow-root.
Since the correct nodeName of ShadowRoot is #document-fragment, we have to specify the nodeName of Author ShadowRoot
as #shadow-root here.
LayoutTests:
* inspector/elements/shadow-dom-modify-chardata-expected.txt:
* inspector/elements/shadow-root-expected.txt:
* inspector/elements/shadow-root.html: Adds <input> test.
Modified Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (137978 => 137979)
--- trunk/LayoutTests/ChangeLog 2012-12-18 04:28:42 UTC (rev 137978)
+++ trunk/LayoutTests/ChangeLog 2012-12-18 04:33:40 UTC (rev 137979)
@@ -1,3 +1,14 @@
+2012-12-17 Shinya Kawanaka <[email protected]>
+
+ Web Inspector: need to visually distinguish UA shadow roots
+ https://bugs.webkit.org/show_bug.cgi?id=104877
+
+ Reviewed by Yury Semikhatsky.
+
+ * inspector/elements/shadow-dom-modify-chardata-expected.txt:
+ * inspector/elements/shadow-root-expected.txt:
+ * inspector/elements/shadow-root.html: Adds <input> test.
+
2012-12-17 Takashi Sakamoto <[email protected]>
fast/dom/shadow/host-wrapper-reclaimed.html is failing on EFL bots
Modified: trunk/LayoutTests/inspector/elements/shadow-dom-modify-chardata-expected.txt (137978 => 137979)
--- trunk/LayoutTests/inspector/elements/shadow-dom-modify-chardata-expected.txt 2012-12-18 04:28:42 UTC (rev 137978)
+++ trunk/LayoutTests/inspector/elements/shadow-dom-modify-chardata-expected.txt 2012-12-18 04:33:40 UTC (rev 137979)
@@ -6,7 +6,7 @@
========= Original ========
- <div id="container">
- <input type="text" id="input1">
- - #shadow-root
+ - #webkit-shadow-root
<div></div>
</input>
</div>
@@ -15,7 +15,7 @@
======== Type text =========
- <div id="container">
- <input type="text" id="input1">
- - #shadow-root
+ - #webkit-shadow-root
+ <div>Bar</div>
</input>
</div>
Modified: trunk/LayoutTests/inspector/elements/shadow-root-expected.txt (137978 => 137979)
--- trunk/LayoutTests/inspector/elements/shadow-root-expected.txt 2012-12-18 04:28:42 UTC (rev 137978)
+++ trunk/LayoutTests/inspector/elements/shadow-root-expected.txt 2012-12-18 04:33:40 UTC (rev 137979)
@@ -1,5 +1,6 @@
This test verified #shadow-root is displayed when showShadowRoot is enabled.
+
- <div id="container">
- <div id="test1">
#shadow-root
@@ -13,5 +14,9 @@
"with "
<span>elements</span>
</div>
+ - <input id="input" type="text">
+ - #webkit-shadow-root
+ <div></div>
+ </input>
</div>
Modified: trunk/LayoutTests/inspector/elements/shadow-root.html (137978 => 137979)
--- trunk/LayoutTests/inspector/elements/shadow-root.html 2012-12-18 04:28:42 UTC (rev 137978)
+++ trunk/LayoutTests/inspector/elements/shadow-root.html 2012-12-18 04:33:40 UTC (rev 137979)
@@ -29,6 +29,7 @@
<div id="test1"></div>
<div id="test2">only test</div>
<div id="test3">with <span>elements</span></div>
+ <input id="input" type="text" />
</div>
<script>
Modified: trunk/Source/WebCore/ChangeLog (137978 => 137979)
--- trunk/Source/WebCore/ChangeLog 2012-12-18 04:28:42 UTC (rev 137978)
+++ trunk/Source/WebCore/ChangeLog 2012-12-18 04:33:40 UTC (rev 137979)
@@ -1,3 +1,22 @@
+2012-12-17 Shinya Kawanaka <[email protected]>
+
+ Web Inspector: need to visually distinguish UA shadow roots
+ https://bugs.webkit.org/show_bug.cgi?id=104877
+
+ Reviewed by Yury Semikhatsky.
+
+ Now we have an option to show ShadowRoot in the Inspector. Since the Inspector has displayed UserAgent ShadowRoot and
+ Author ShadowRoot as the same #shadow-root, a user could not distinguish them.
+
+ We would like to show UserAgent ShadowRoot as #webkit-shadow-root.
+
+ Test: inspector/shadow-root.html
+
+ * inspector/InspectorDOMAgent.cpp:
+ (WebCore::InspectorDOMAgent::buildObjectForNode): Make nodeName of UserAgent ShadowRoot #webkit-shadow-root.
+ Since the correct nodeName of ShadowRoot is #document-fragment, we have to specify the nodeName of Author ShadowRoot
+ as #shadow-root here.
+
2012-12-17 Huang Dongsung <[email protected]>
Coordinated Graphics: Refactor TiledBackingStore code in CoordinatedGraphicsLayer.
Modified: trunk/Source/WebCore/inspector/InspectorDOMAgent.cpp (137978 => 137979)
--- trunk/Source/WebCore/inspector/InspectorDOMAgent.cpp 2012-12-18 04:28:42 UTC (rev 137978)
+++ trunk/Source/WebCore/inspector/InspectorDOMAgent.cpp 2012-12-18 04:33:40 UTC (rev 137979)
@@ -1251,6 +1251,15 @@
localName = node->localName();
break;
case Node::DOCUMENT_FRAGMENT_NODE:
+ if (node->isShadowRoot()) {
+ if (toShadowRoot(node)->type() == ShadowRoot::UserAgentShadowRoot)
+ nodeName = "#webkit-shadow-root";
+ else
+ nodeName = "#shadow-root";
+ } else
+ nodeName = node->nodeName();
+ localName = node->localName();
+ break;
case Node::DOCUMENT_NODE:
case Node::ELEMENT_NODE:
default:
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes