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

Side by Side Diff: LayoutTests/inspector/elements/node-xpath.xhtml

Issue 16561003: DevTools: Inspect element mode does not select element in ShadowDOM (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: For landing Created 7 years, 6 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 <!-- Pre-comment --> 1 <!-- Pre-comment -->
2 <html xmlns="http://www.w3.org/1999/xhtml"> 2 <html xmlns="http://www.w3.org/1999/xhtml">
3 <head> 3 <head>
4 <script src="../../http/tests/inspector/inspector-test.js" id="script-id"></scri pt> 4 <script src="../../http/tests/inspector/inspector-test.js" id="script-id"></scri pt>
5 <script src="../../http/tests/inspector/elements-test.js"></script> 5 <script src="../../http/tests/inspector/elements-test.js"></script>
6 <script id="test-script"> 6 <script id="test-script">
7 //<![CDATA[ 7 //<![CDATA[
8 function test() 8 function test()
9 { 9 {
10 InspectorTest.expandElementsTree(dumpNodes.bind(null, "")); 10 InspectorTest.expandElementsTree(dumpNodes.bind(null, ""));
11 var doc; 11 var doc;
12 12
13 function dumpNodes(prefix, node) 13 function dumpNodes(prefix, node)
14 { 14 {
15 if (!doc) { 15 if (!doc) {
16 doc = getDocumentElement(); 16 doc = getDocumentElement();
17 node = doc; 17 node = doc;
18 } 18 }
19 if (node.getAttribute("id") === "test-script") 19 if (node.getAttribute("id") === "test-script")
20 return; 20 return;
21 dumpNodeData(node, prefix); 21 dumpNodeData(node, prefix);
22 var children = node.children; 22 var children = node.children();
23 for (var i = 0; children && i < children.length; ++i) 23 for (var i = 0; children && i < children.length; ++i)
24 dumpNodes(prefix + " ", children[i]); 24 dumpNodes(prefix + " ", children[i]);
25 if (node === doc) 25 if (node === doc)
26 InspectorTest.completeTest(); 26 InspectorTest.completeTest();
27 } 27 }
28 28
29 function getDocumentElement() 29 function getDocumentElement()
30 { 30 {
31 var map = WebInspector.domAgent._idToDOMNode; 31 var map = WebInspector.domAgent._idToDOMNode;
32 for (var id in map) { 32 for (var id in map) {
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 <div id="container"> 65 <div id="container">
66 <div id="id3" class="foo">3 Prefix <![CDATA[<greeting>Hello, world!</greetin g>]]> Suffix</div> 66 <div id="id3" class="foo">3 Prefix <![CDATA[<greeting>Hello, world!</greetin g>]]> Suffix</div>
67 <div id="id4" class="foo">4</div> 67 <div id="id4" class="foo">4</div>
68 <div id="id5" class="foo">5</div> 68 <div id="id5" class="foo">5</div>
69 <div id="id6" class="foo">6</div> 69 <div id="id6" class="foo">6</div>
70 </div> 70 </div>
71 71
72 </body> 72 </body>
73 </html> 73 </html>
74 <!-- Post-comment --> 74 <!-- Post-comment -->
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698