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

Side by Side Diff: LayoutTests/svg/custom/use-on-use-with-child.svg

Issue 278033003: Avoid using instanceRoot in layout tests (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 7 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
OLDNEW
1 <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/TR/2001/REC-SV G-20010904/DTD/svg11.dtd"> 1 <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/TR/2001/REC-SV G-20010904/DTD/svg11.dtd">
2 <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlin k"> 2 <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlin k">
3 <title id="viewer_title">Mouse Over the Red Dot And Wait For the Crash</titl e> 3 <title id="viewer_title">Mouse Over the Red Dot And Wait For the Crash</titl e>
4 <defs> 4 <defs>
5 <circle id="rim" cx="0" cy="0" r="70"/> 5 <circle id="rim" cx="0" cy="0" r="70"/>
6 <g id="loupePlus"> 6 <g id="loupePlus">
7 <use id="useRim" xlink:href="#rim" fill="#e33c31"> 7 <use id="useRim" xlink:href="#rim" fill="#e33c31">
8 <set /> 8 <set />
9 </use> 9 </use>
10 </g> 10 </g>
11 </defs> 11 </defs>
12 12
13 <use id="zoomplus" xlink:href="#loupePlus" x="300" y="300" > 13 <use id="zoomplus" xlink:href="#loupePlus" x="300" y="300" >
14 </use> 14 </use>
15 <foreignObject><pre id="console" xmlns="http://www.w3.org/1999/xhtml"/></for eignObject> 15 <foreignObject><pre id="console" xmlns="http://www.w3.org/1999/xhtml"/></for eignObject>
16 <script> 16 <script>
17 function makeCrash(){ 17 function makeCrash(){
18 if (window.eventSender) { 18 if (window.eventSender) {
19 eventSender.dragMode = false; 19 eventSender.dragMode = false;
20 eventSender.mouseMoveTo(300, 300); 20 eventSender.mouseMoveTo(300, 300);
21 eventSender.mouseDown(); 21 eventSender.mouseDown();
22 eventSender.mouseUp(); 22 eventSender.mouseUp();
23 } 23 }
24 } 24 }
25 // If you like, you can make a crash. 25 // If you like, you can make a crash.
26 // makeCrash(); 26 // makeCrash();
27 27
28 var console = document.getElementById("console"); 28 var console = document.getElementById("console");
29 function println(string) 29 function print(string)
30 { 30 {
31 console.textContent += string + '\n'; 31 console.textContent += string;
32 } 32 }
33 33
34 function printInstanceTree( obj, indent ) 34 function printInstanceTree( obj, indent )
35 { 35 {
36 indent += " "; 36 indent += " ";
37 println(indent + "id = " + obj.correspondingElement.id + " this = " + obj + " correspondingElement = " + obj.correspondingElement); 37 print(indent);
38 if (obj.id) {
39 print(" id = " + obj.id);
40 }
41 print(" this = " + obj + "\n");
38 for (var m = obj.firstChild; m != null; m = m.nextSibling ) { 42 for (var m = obj.firstChild; m != null; m = m.nextSibling ) {
39 printInstanceTree(m, indent); 43 printInstanceTree(m, indent);
40 } 44 }
41 } 45 }
42 var useobj = document.getElementById("zoomplus").instanceRoot; 46 var useobj = internals.shadowRoot(document.getElementById("zoomplus"));
43 println("The instance tree of use element zoomplus:\n"); 47 print("The instance tree of use element zoomplus:\n");
44 printInstanceTree(useobj,""); 48 printInstanceTree(useobj,"");
45 49
46 if (window.testRunner){ 50 if (window.testRunner){
47 testRunner.dumpAsText(); 51 testRunner.dumpAsText();
48 } 52 }
49 53
50 </script> 54 </script>
51 </svg> 55 </svg>
OLDNEW
« no previous file with comments | « LayoutTests/svg/custom/use-modify-target-symbol.svg ('k') | LayoutTests/svg/custom/use-on-use-with-child-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698