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

Side by Side Diff: LayoutTests/transforms/3d/general/matrix-with-zoom-3d.html

Issue 428533003: Remove webkitConvertPointFromPageToNode() and webkitConvertPointFromNodeToPage() (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 4 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
« no previous file with comments | « LayoutTests/transforms/3d/general/cssmatrix-3d-zoom.html ('k') | Source/core/dom/Node.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <html> 1 <html>
2 <head> 2 <head>
3 <style> 3 <style>
4 body { 4 body {
5 zoom: 1.2; 5 zoom: 1.2;
6 padding: 0; 6 padding: 0;
7 margin: 0; 7 margin: 0;
8 -webkit-transform-style: perserve-3d; 8 -webkit-transform-style: perserve-3d;
9 -webkit-perspective: 1000px; 9 -webkit-perspective: 1000px;
10 } 10 }
(...skipping 19 matching lines...) Expand all
30 </style> 30 </style>
31 <script type="text/javascript"> 31 <script type="text/javascript">
32 32
33 function runTest() { 33 function runTest() {
34 if (!window.testRunner) { 34 if (!window.testRunner) {
35 35
36 var id1 = "a"; 36 var id1 = "a";
37 var id2 = "b"; 37 var id2 = "b";
38 var element1 = document.getElementById(id1); 38 var element1 = document.getElementById(id1);
39 var element2 = document.getElementById(id2); 39 var element2 = document.getElementById(id2);
40 var x1 = webkitConvertPointFromNodeToPage(element1, new WebKitPoint(0,0) ).x; 40 var x1 = element1.getBoundingClientRect().left;
41 var y1 = webkitConvertPointFromNodeToPage(element1, new WebKitPoint(0,0) ).y; 41 var y1 = element1.getBoundingClientRect().top;
42 var x2 = webkitConvertPointFromNodeToPage(element2, new WebKitPoint(0,0) ).x; 42 var x2 = element2.getBoundingClientRect().left;
43 var y2 = webkitConvertPointFromNodeToPage(element2, new WebKitPoint(0,0) ).y; 43 var y2 = element2.getBoundingClientRect().top;
44 44
45 var resultString = ''; 45 var resultString = '';
46 if (x1 == x2 && y1 == y2) { 46 if (x1 == x2 && y1 == y2) {
47 resultString += "PASS - Element " + id1 + " and Element " + id2 + " had identical positions"; 47 resultString += "PASS - Element " + id1 + " and Element " + id2 + " had identical positions";
48 } else { 48 } else {
49 resultString += "FAIL - Element " + id1 + " and Element " + id2 + " had different positions"; 49 resultString += "FAIL - Element " + id1 + " and Element " + id2 + " had different positions";
50 } 50 }
51 51
52 document.body.appendChild(document.createTextNode(resultString)); 52 document.body.appendChild(document.createTextNode(resultString));
53 } 53 }
54 } 54 }
55 </script> 55 </script>
56 </head> 56 </head>
57 <body onload="runTest();"> 57 <body onload="runTest();">
58 58
59 <!-- You should see green box only. If you see red, the test has failed --> 59 <!-- You should see green box only. If you see red, the test has failed -->
60 60
61 <div id='a' class="box translate"></div> 61 <div id='a' class="box translate"></div>
62 <div id='b' class="box matrix"></div> 62 <div id='b' class="box matrix"></div>
63 63
64 </body> 64 </body>
65 </html> 65 </html>
OLDNEW
« no previous file with comments | « LayoutTests/transforms/3d/general/cssmatrix-3d-zoom.html ('k') | Source/core/dom/Node.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698