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

Side by Side Diff: third_party/WebKit/LayoutTests/images/image-change-without-resize-shouldnt-layout.html

Issue 2496663002: Merge css3/image/ and fast/images/ to images/ (Closed)
Patch Set: Address failing tests (3 of them) Created 4 years, 1 month 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 <title>This test ensures that when an image changes, but doesn't change size (li ke in an Animated GIF), we don't force a Layout.</title> 2 <title>This test ensures that when an image changes, but doesn't change size (li ke in an Animated GIF), we don't force a Layout.</title>
3 <script src="../../resources/testharness.js"></script> 3 <script src="../resources/testharness.js"></script>
4 <script src="../../resources/testharnessreport.js"></script> 4 <script src="../resources/testharnessreport.js"></script>
5 <div style="float: left;"> 5 <div style="float: left;">
6 <img style="max-width: 100%" src="../replaced/resources/1x1-blue.png"> 6 <img style="max-width: 100%" src="../fast/replaced/resources/1x1-blue.png">
7 </div> 7 </div>
8 <script> 8 <script>
9 async_test(function(t) { 9 async_test(function(t) {
10 window.onload = t.step_func(function() { 10 window.onload = t.step_func(function() {
11 document.documentElement.offsetTop; 11 document.documentElement.offsetTop;
12 var img = document.querySelector("img"); 12 var img = document.querySelector("img");
13 img.src = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAMAAAA oyzS7AAAABGdBTUEAAK/INwWK6QAAABl0RVh0U29mdHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAA GUExURf8AAAAAAEGjEgMAAAAMSURBVHjaYmAACDAAAAIAAU9tWeEAAAAASUVORK5CYII="; 13 img.src = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAMAAAA oyzS7AAAABGdBTUEAAK/INwWK6QAAABl0RVh0U29mdHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAA GUExURf8AAAAAAEGjEgMAAAAMSURBVHjaYmAACDAAAAIAAU9tWeEAAAAASUVORK5CYII=";
14 assert_equals(internals.needsLayoutCount(), 0); 14 assert_equals(internals.needsLayoutCount(), 0);
15 img.onload = t.step_func_done(function() { 15 img.onload = t.step_func_done(function() {
16 assert_equals(internals.needsLayoutCount(), 0); 16 assert_equals(internals.needsLayoutCount(), 0);
17 }); 17 });
18 }); 18 });
19 }); 19 });
20 </script> 20 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698