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

Side by Side Diff: LayoutTests/fast/hidpi/image-srcset-intrinsic-size.html

Issue 25105004: Use srcset's resource pixel density to determine intrinsic size (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@cleantests
Patch Set: Fixed crash+rebased Created 7 years, 2 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
(Empty)
1 <html>
2 <head>
3 <script>
4 window.targetScaleFactor = 2;
5 </script>
6 <script src="resources/srcset-helper.js"></script>
7 <script src="../js/resources/js-test-pre.js"></script>
8 <script>
9 addEventListener("load", function() {
10 shouldBeTrue('document.getElementById("foo").clientWidth==200');
11 shouldBeTrue('document.getElementById("foo2").clientWidth==400');
12 shouldBeTrue('document.getElementById("foo3").clientWidth==100');
13 shouldBeTrue('document.getElementById("foo4").clientWidth==200');
14 }, false);
15 </script>
16 </head>
17
18 <body id="body">
19 <div>
20 This test passes if the images are all displayed with appropriate dimens ions.
21 </div>
22 <img id="foo" srcset="resources/blue-100-px-square.png 1x, resources/deleteB utton.png 3x, resources/green-200-px-square.png 2x">
23 <br>
24 <img id="foo2" src="resources/green-200-px-square.png">
25 <br>
26 <img id="foo3" srcset="resources/srcset.svg 2x">
27 <br>
28 <img id="foo4" src="resources/srcset.svg">
29 </body>
30 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698