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

Side by Side Diff: third_party/WebKit/LayoutTests/images/color-profile-svg.html

Issue 2938543003: Remove almost all Javascript calls to setColorProfile (Closed)
Patch Set: Created 3 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
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <html> 2 <html>
3 <script src="../resources/run-after-layout-and-paint.js"></script> 3 <script src="../resources/run-after-layout-and-paint.js"></script>
4 4
5 <style> 5 <style>
6 body { overflow: hidden; margin: 0px } 6 body { overflow: hidden; margin: 0px }
7 </style> 7 </style>
8 8
9 <!-- The blue sector of the image <pattern> should be at the 12 o'clock. --> 9 <!-- The blue sector of the image <pattern> should be at the 12 o'clock. -->
10 <body> 10 <body>
11 <svg width="800px" height="400px"> 11 <svg width="800px" height="400px">
12 <pattern id="pattern" patternUnits="userSpaceOnUse" width="400" height="400"> 12 <pattern id="pattern" patternUnits="userSpaceOnUse" width="400" height="400">
13 <image onload="top.load()" xlink:href="resources/red-at-12-oclock-with-colo r-profile.jpg" width="400" height="400"/> 13 <image onload="top.load()" xlink:href="resources/red-at-12-oclock-with-colo r-profile.jpg" width="400" height="400"/>
14 </pattern> 14 </pattern>
15 <rect width="800" height="400" style="fill: url(#pattern)"/> 15 <rect width="800" height="400" style="fill: url(#pattern)"/>
16 </svg> 16 </svg>
17 </body> 17 </body>
18 18
19 <script> 19 <script>
20 function load() { 20 function load() {
21 if (window.testRunner) 21 if (window.testRunner)
22 runAfterLayoutAndPaint(changeColorProfile); 22 runAfterLayoutAndPaint(function() { testRunner.notifyDone() });
23 }
24
25 function changeColorProfile() {
26 testRunner.setColorProfile('colorSpin', done);
27 }
28
29 function done() {
30 setTimeout(function() { testRunner.notifyDone() }, 0);
31 } 23 }
32 24
33 if (window.testRunner) { 25 if (window.testRunner) {
34 testRunner.dumpAsTextWithPixelResults(); 26 testRunner.dumpAsTextWithPixelResults();
35 testRunner.waitUntilDone(); 27 testRunner.waitUntilDone();
36 } 28 }
37 </script> 29 </script>
38 </html> 30 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698