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

Side by Side Diff: third_party/WebKit/LayoutTests/fast/images/color-profile-image-scroll-into-view.html

Issue 1309393007: [poc] redecode Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: resetColorProfileForTesting rename Created 5 years 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
(Empty)
1 <!DOCTYPE html>
2 <html>
3 <script src="../../resources/run-after-layout-and-paint.js"/></script>
4
5 <style>
6 div { height: 55px; overflow: hidden; }
7 img { width: 250px; }
8 </style>
9
10 <body>
11 <!-- The blue sector of the images should be at 12 o'clock. -->
12 <div>
13 <img src="resources/red-at-12-oclock-with-color-profile.jpg">
14 <img src="resources/red-at-12-oclock-with-color-profile.jpg">
15 <img src="resources/red-at-12-oclock-with-color-profile.jpg">
16 </div>
17 <div id="test" style="position: relative; top: 1200px; margin-bottom: 300px">
18 <img src="resources/webp-color-profile-lossy.webp">
19 <img src="resources/red-at-12-oclock-with-color-profile.jpg">
20 <img src="resources/red-at-12-oclock-with-color-profile.png">
21 <div>
22 </body>
23
24 <script>
25 window.onload = function() {
26 runAfterLayoutAndPaint(window.testRunner ? changeColorProfile : scroll);
27 };
28
29 function changeColorProfile() {
30 setTimeout(function() { testRunner.setColorProfile('test', scroll) }, 100);
31 }
32
33 function scroll() {
34 window.addEventListener("scroll", function() {
35 if (window.testRunner)
36 setTimeout(function() { testRunner.notifyDone() }, 0);
37 });
38
39 test.scrollIntoView();
40 }
41
42 if (window.internals)
43 internals.settings.setImageColorProfilesEnabled(true);
44
45 if (window.testRunner) {
46 testRunner.dumpAsTextWithPixelResults();
47 testRunner.waitUntilDone();
48 }
49 </script>
50 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698