<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[186401] releases/WebKitGTK/webkit-2.8</title>
</head>
<body>
<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/186401">186401</a></dd>
<dt>Author</dt> <dd>carlosgc@webkit.org</dd>
<dt>Date</dt> <dd>2015-07-06 22:56:18 -0700 (Mon, 06 Jul 2015)</dd>
</dl>
<h3>Log Message</h3>
<pre>Merge <a href="http://trac.webkit.org/projects/webkit/changeset/185310">r185310</a> - REGRESSION (<a href="http://trac.webkit.org/projects/webkit/changeset/181720">r181720</a>): Unnecessary layout triggered any time animated GIF advances to a new frame
https://bugs.webkit.org/show_bug.cgi?id=145733
Reviewed by Andreas Kling.
Source/WebCore:
Test: fast/images/animated-gif-no-layout.html
* rendering/RenderImage.cpp:
(WebCore::RenderImage::styleDidChange): Correctly pass ImageSizeChangeNone in cases
where we don't need to report a change in intrinsic size that happened outside the
repaintOrMarkForLayout function.
(WebCore::RenderImage::repaintOrMarkForLayout): Move work that should only be done
when size changed inside the if statement.
* testing/Internals.cpp:
(WebCore::Internals::layoutCount): Added.
* testing/Internals.h: Added layoutCount.
* testing/Internals.idl: Ditto.
LayoutTests:
* TestExpectations: Expect image failures on the animated GIF tests (the one
old one I am fixing and the one new one I am adding) because they don't yet work
under DumpRenderTree.
* fast/images/animated-gif-no-layout-expected.html: Added.
* fast/images/animated-gif-no-layout.html: Added.
* fast/images/gif-loop-count-expected.html: Added. This test was worthless as a render
tree dump test, and only valuable as a pixel test. And that hid the fact that it was
failing under WebKit1. Changing it to a reference test makes it a valuable test again.
* fast/images/gif-loop-count-expected.png: Removed.
* fast/images/gif-loop-count-expected.txt: Removed.
* platform/wk2/TestExpectations: Expect successes on these two tests.</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#releasesWebKitGTKwebkit28LayoutTestsChangeLog">releases/WebKitGTK/webkit-2.8/LayoutTests/ChangeLog</a></li>
<li><a href="#releasesWebKitGTKwebkit28LayoutTestsplatformwk2TestExpectations">releases/WebKitGTK/webkit-2.8/LayoutTests/platform/wk2/TestExpectations</a></li>
<li><a href="#releasesWebKitGTKwebkit28SourceWebCoreChangeLog">releases/WebKitGTK/webkit-2.8/Source/WebCore/ChangeLog</a></li>
<li><a href="#releasesWebKitGTKwebkit28SourceWebCorerenderingRenderImagecpp">releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderImage.cpp</a></li>
<li><a href="#releasesWebKitGTKwebkit28SourceWebCoretestingInternalscpp">releases/WebKitGTK/webkit-2.8/Source/WebCore/testing/Internals.cpp</a></li>
<li><a href="#releasesWebKitGTKwebkit28SourceWebCoretestingInternalsh">releases/WebKitGTK/webkit-2.8/Source/WebCore/testing/Internals.h</a></li>
<li><a href="#releasesWebKitGTKwebkit28SourceWebCoretestingInternalsidl">releases/WebKitGTK/webkit-2.8/Source/WebCore/testing/Internals.idl</a></li>
</ul>
<h3>Added Paths</h3>
<ul>
<li><a href="#releasesWebKitGTKwebkit28LayoutTestsfastimagesanimatedgifnolayoutexpectedhtml">releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/animated-gif-no-layout-expected.html</a></li>
<li><a href="#releasesWebKitGTKwebkit28LayoutTestsfastimagesanimatedgifnolayouthtml">releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/animated-gif-no-layout.html</a></li>
<li><a href="#releasesWebKitGTKwebkit28LayoutTestsfastimagesgifloopcountexpectedhtml">releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/gif-loop-count-expected.html</a></li>
</ul>
<h3>Removed Paths</h3>
<ul>
<li><a href="#releasesWebKitGTKwebkit28LayoutTestsfastimagesgifloopcountexpectedpng">releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/gif-loop-count-expected.png</a></li>
<li><a href="#releasesWebKitGTKwebkit28LayoutTestsfastimagesgifloopcountexpectedtxt">releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/gif-loop-count-expected.txt</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="releasesWebKitGTKwebkit28LayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/LayoutTests/ChangeLog (186400 => 186401)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/LayoutTests/ChangeLog        2015-07-07 05:37:38 UTC (rev 186400)
+++ releases/WebKitGTK/webkit-2.8/LayoutTests/ChangeLog        2015-07-07 05:56:18 UTC (rev 186401)
</span><span class="lines">@@ -1,3 +1,25 @@
</span><ins>+2015-06-07 Darin Adler <darin@apple.com>
+
+ REGRESSION (r181720): Unnecessary layout triggered any time animated GIF advances to a new frame
+ https://bugs.webkit.org/show_bug.cgi?id=145733
+
+ Reviewed by Andreas Kling.
+
+ * TestExpectations: Expect image failures on the animated GIF tests (the one
+ old one I am fixing and the one new one I am adding) because they don't yet work
+ under DumpRenderTree.
+
+ * fast/images/animated-gif-no-layout-expected.html: Added.
+ * fast/images/animated-gif-no-layout.html: Added.
+
+ * fast/images/gif-loop-count-expected.html: Added. This test was worthless as a render
+ tree dump test, and only valuable as a pixel test. And that hid the fact that it was
+ failing under WebKit1. Changing it to a reference test makes it a valuable test again.
+ * fast/images/gif-loop-count-expected.png: Removed.
+ * fast/images/gif-loop-count-expected.txt: Removed.
+
+ * platform/wk2/TestExpectations: Expect successes on these two tests.
+
</ins><span class="cx"> 2015-06-05 Chris Dumez <cdumez@apple.com>
</span><span class="cx">
</span><span class="cx"> Regression(r176212): Broke app switching on iCloud.com
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit28LayoutTestsfastimagesanimatedgifnolayoutexpectedhtml"></a>
<div class="addfile"><h4>Added: releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/animated-gif-no-layout-expected.html (0 => 186401)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/animated-gif-no-layout-expected.html         (rev 0)
+++ releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/animated-gif-no-layout-expected.html        2015-07-07 05:56:18 UTC (rev 186401)
</span><span class="lines">@@ -0,0 +1,2 @@
</span><ins>+<div style="position:absolute;left:0;top:0;width:100;height:100;background-color:#21B14D"></div>
+<img src="resources/rgb-jpeg-green.jpg" style="position:absolute;left:0;top:150">
</ins></span></pre></div>
<a id="releasesWebKitGTKwebkit28LayoutTestsfastimagesanimatedgifnolayouthtml"></a>
<div class="addfile"><h4>Added: releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/animated-gif-no-layout.html (0 => 186401)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/animated-gif-no-layout.html         (rev 0)
+++ releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/animated-gif-no-layout.html        2015-07-07 05:56:18 UTC (rev 186401)
</span><span class="lines">@@ -0,0 +1,43 @@
</span><ins>+<script>
+ // This test waits for a GIF repaint and double checks that there is a repaint only,
+ // no layout. If the test passes, there are two green squares. If it fails, then one
+ // or both of the squares is red instead.
+
+ var layoutCountBeforeTimer;
+
+ function animationComplete()
+ {
+ document.body.offsetWidth; // Explicitly trigger a layout.
+
+ if (window.internals && window.testRunner) {
+ var count = internals.layoutCount - layoutCountBeforeTimer;
+ if (count == 0) {
+ var indicator = document.getElementById("indicator");
+ indicator.addEventListener("load", function() { testRunner.notifyDone(); })
+ indicator.src = "resources/rgb-jpeg-green.jpg";
+ return;
+ }
+ testRunner.notifyDone();
+ }
+ }
+
+ function test()
+ {
+ document.body.offsetWidth; // Explicitly trigger a layout.
+
+ if (window.internals && window.testRunner) {
+ testRunner.waitUntilDone();
+ layoutCountBeforeTimer = internals.layoutCount;
+ }
+
+ // The 200ms value here is longer than the time it takes for gif-loop-count.gif
+ // to advance from its first frame to its second. There should be no race because
+ // the GIF timer should already be scheduled and this timer should share the
+ // same time base.
+ setTimeout(animationComplete, 200);
+ }
+</script>
+<body onload="test()">
+<img src="resources/gif-loop-count.gif" style="position:absolute;left:0;top:0">
+<img id="indicator" src="resources/rgb-jpeg-red.jpg" style="position:absolute;left:0;top:150">
+</body>
</ins></span></pre></div>
<a id="releasesWebKitGTKwebkit28LayoutTestsfastimagesgifloopcountexpectedhtml"></a>
<div class="addfile"><h4>Added: releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/gif-loop-count-expected.html (0 => 186401)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/gif-loop-count-expected.html         (rev 0)
+++ releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/gif-loop-count-expected.html        2015-07-07 05:56:18 UTC (rev 186401)
</span><span class="lines">@@ -0,0 +1 @@
</span><ins>+<div style="position:absolute;left:0;top:0;width:100;height:100;background-color:#21B14D"></div>
</ins></span></pre></div>
<a id="releasesWebKitGTKwebkit28LayoutTestsfastimagesgifloopcountexpectedpng"></a>
<div class="binary"><h4>Deleted: releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/gif-loop-count-expected.png</h4>
<pre class="diff"><span>
<span class="cx">(Binary files differ)
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit28LayoutTestsfastimagesgifloopcountexpectedtxt"></a>
<div class="delfile"><h4>Deleted: releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/gif-loop-count-expected.txt (186400 => 186401)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/gif-loop-count-expected.txt        2015-07-07 05:37:38 UTC (rev 186400)
+++ releases/WebKitGTK/webkit-2.8/LayoutTests/fast/images/gif-loop-count-expected.txt        2015-07-07 05:56:18 UTC (rev 186401)
</span><span class="lines">@@ -1,9 +0,0 @@
</span><del>-layer at (0,0) size 800x600
- RenderView at (0,0) size 800x600
-layer at (0,0) size 800x600
- RenderBlock {HTML} at (0,0) size 800x600
- RenderBody {BODY} at (8,8) size 784x584
-layer at (0,0) size 100x100
- RenderImage {IMG} at (0,0) size 100x100
-layer at (0,0) size 100x100
- RenderImage {IMG} at (0,0) size 100x100
</del></span></pre></div>
<a id="releasesWebKitGTKwebkit28LayoutTestsplatformwk2TestExpectations"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/LayoutTests/platform/wk2/TestExpectations (186400 => 186401)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/LayoutTests/platform/wk2/TestExpectations        2015-07-07 05:37:38 UTC (rev 186400)
+++ releases/WebKitGTK/webkit-2.8/LayoutTests/platform/wk2/TestExpectations        2015-07-07 05:56:18 UTC (rev 186401)
</span><span class="lines">@@ -36,6 +36,7 @@
</span><span class="cx"> ### (2) Classified failures without bug reports (yet)
</span><span class="cx"> ### (3) Unclassified failures
</span><span class="cx"> ### (4) Features that are not supported in WebKit2 and likely never will be
</span><ins>+### (5) Progressions, expected successes that are expected failures in WebKit1.
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> ########################################
</span><span class="lines">@@ -674,7 +675,16 @@
</span><span class="cx"> ### END OF (4) Features that are not supported in WebKit2 and likely never will be
</span><span class="cx"> ########################################
</span><span class="cx">
</span><ins>+########################################
+### START OF (5) Progressions, expected successes that are expected failures in WebKit1.
</ins><span class="cx">
</span><ins>+# DumpRenderTree does not allow GIFs to animate, thus animated GIF tests don't work in WebKit1.
+fast/images/animated-gif-no-layout.html [ Pass ]
+fast/images/gif-loop-count.html [ Pass ]
+
+### END OF (5) Progressions, expected successes that are expected failures in WebKit1.
+########################################
+
</ins><span class="cx"> ###### This file has four sections. When adding new tests, make sure to
</span><span class="cx"> ###### add to the right section:
</span><span class="cx">
</span><span class="lines">@@ -682,3 +692,4 @@
</span><span class="cx"> ### (2) Classified failures without bug reports (yet)
</span><span class="cx"> ### (3) Unclassified failures
</span><span class="cx"> ### (4) Features that are not supported in WebKit2 and likely never will be
</span><ins>+### (5) Progressions, expected successes that are expected failures in WebKit1.
</ins></span></pre></div>
<a id="releasesWebKitGTKwebkit28SourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/Source/WebCore/ChangeLog (186400 => 186401)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/Source/WebCore/ChangeLog        2015-07-07 05:37:38 UTC (rev 186400)
+++ releases/WebKitGTK/webkit-2.8/Source/WebCore/ChangeLog        2015-07-07 05:56:18 UTC (rev 186401)
</span><span class="lines">@@ -1,3 +1,24 @@
</span><ins>+2015-06-07 Darin Adler <darin@apple.com>
+
+ REGRESSION (r181720): Unnecessary layout triggered any time animated GIF advances to a new frame
+ https://bugs.webkit.org/show_bug.cgi?id=145733
+
+ Reviewed by Andreas Kling.
+
+ Test: fast/images/animated-gif-no-layout.html
+
+ * rendering/RenderImage.cpp:
+ (WebCore::RenderImage::styleDidChange): Correctly pass ImageSizeChangeNone in cases
+ where we don't need to report a change in intrinsic size that happened outside the
+ repaintOrMarkForLayout function.
+ (WebCore::RenderImage::repaintOrMarkForLayout): Move work that should only be done
+ when size changed inside the if statement.
+
+ * testing/Internals.cpp:
+ (WebCore::Internals::layoutCount): Added.
+ * testing/Internals.h: Added layoutCount.
+ * testing/Internals.idl: Ditto.
+
</ins><span class="cx"> 2015-06-06 Ryosuke Niwa <rniwa@webkit.org>
</span><span class="cx">
</span><span class="cx"> Typing is slow in Gmail on iPads
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit28SourceWebCorerenderingRenderImagecpp"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderImage.cpp (186400 => 186401)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderImage.cpp        2015-07-07 05:37:38 UTC (rev 186400)
+++ releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderImage.cpp        2015-07-07 05:56:18 UTC (rev 186401)
</span><span class="lines">@@ -214,7 +214,7 @@
</span><span class="cx"> }
</span><span class="cx"> #if ENABLE(CSS_IMAGE_ORIENTATION)
</span><span class="cx"> if (diff == StyleDifferenceLayout && oldStyle->imageOrientation() != style().imageOrientation())
</span><del>- return repaintOrMarkForLayout(ImageSizeChangeForAltText);
</del><ins>+ return repaintOrMarkForLayout(ImageSizeChangeNone);
</ins><span class="cx"> #endif
</span><span class="cx">
</span><span class="cx"> #if ENABLE(CSS_IMAGE_RESOLUTION)
</span><span class="lines">@@ -222,7 +222,7 @@
</span><span class="cx"> && (oldStyle->imageResolution() != style().imageResolution()
</span><span class="cx"> || oldStyle->imageResolutionSnap() != style().imageResolutionSnap()
</span><span class="cx"> || oldStyle->imageResolutionSource() != style().imageResolutionSource()))
</span><del>- repaintOrMarkForLayout(ImageSizeChangeForAltText);
</del><ins>+ repaintOrMarkForLayout(ImageSizeChangeNone);
</ins><span class="cx"> #endif
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -304,26 +304,28 @@
</span><span class="cx">
</span><span class="cx"> bool imageSourceHasChangedSize = oldIntrinsicSize != newIntrinsicSize || imageSizeChange != ImageSizeChangeNone;
</span><span class="cx">
</span><del>- if (imageSourceHasChangedSize)
</del><ins>+ if (imageSourceHasChangedSize) {
</ins><span class="cx"> setPreferredLogicalWidthsDirty(true);
</span><span class="cx">
</span><del>- // If the actual area occupied by the image has changed and it is not constrained by style then a layout is required.
- bool imageSizeIsConstrained = style().logicalWidth().isSpecified() && style().logicalHeight().isSpecified();
- bool needsLayout = !imageSizeIsConstrained && imageSourceHasChangedSize;
</del><ins>+ // If the actual area occupied by the image has changed and it is not constrained by style then a layout is required.
+ bool imageSizeIsConstrained = style().logicalWidth().isSpecified() && style().logicalHeight().isSpecified();
</ins><span class="cx">
</span><del>- // FIXME: We only need to recompute the containing block's preferred size
- // if the containing block's size depends on the image's size (i.e., the container uses shrink-to-fit sizing).
- // There's no easy way to detect that shrink-to-fit is needed, always force a layout.
- bool containingBlockNeedsToRecomputePreferredSize =
- style().logicalWidth().isPercent()
- || style().logicalMaxWidth().isPercent()
- || style().logicalMinWidth().isPercent();
</del><ins>+ // FIXME: We only need to recompute the containing block's preferred size
+ // if the containing block's size depends on the image's size (i.e., the container uses shrink-to-fit sizing).
+ // There's no easy way to detect that shrink-to-fit is needed, always force a layout.
+ bool containingBlockNeedsToRecomputePreferredSize =
+ style().logicalWidth().isPercent()
+ || style().logicalMaxWidth().isPercent()
+ || style().logicalMinWidth().isPercent();
</ins><span class="cx">
</span><del>- bool layoutSizeDependsOnIntrinsicSize = style().aspectRatioType() == AspectRatioFromIntrinsic;
</del><ins>+ bool layoutSizeDependsOnIntrinsicSize = style().aspectRatioType() == AspectRatioFromIntrinsic;
</ins><span class="cx">
</span><del>- if (needsLayout || containingBlockNeedsToRecomputePreferredSize || layoutSizeDependsOnIntrinsicSize) {
- setNeedsLayout();
- return;
</del><ins>+ if (!imageSizeIsConstrained || containingBlockNeedsToRecomputePreferredSize || layoutSizeDependsOnIntrinsicSize) {
+ // FIXME: It's not clear that triggering a layout guarantees a repaint in all cases.
+ // But many callers do depend on this code causing a layout.
+ setNeedsLayout();
+ return;
+ }
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> if (everHadLayout() && !selfNeedsLayout()) {
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit28SourceWebCoretestingInternalscpp"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/Source/WebCore/testing/Internals.cpp (186400 => 186401)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/Source/WebCore/testing/Internals.cpp        2015-07-07 05:37:38 UTC (rev 186400)
+++ releases/WebKitGTK/webkit-2.8/Source/WebCore/testing/Internals.cpp        2015-07-07 05:56:18 UTC (rev 186401)
</span><span class="lines">@@ -2006,6 +2006,14 @@
</span><span class="cx"> document->updateLayoutIgnorePendingStylesheets(Document::RunPostLayoutTasks::Synchronously);
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+unsigned Internals::layoutCount() const
+{
+ Document* document = contextDocument();
+ if (!document || !document->view())
+ return 0;
+ return document->view()->layoutCount();
+}
+
</ins><span class="cx"> #if !PLATFORM(IOS)
</span><span class="cx"> static const char* cursorTypeToString(Cursor::Type cursorType)
</span><span class="cx"> {
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit28SourceWebCoretestingInternalsh"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/Source/WebCore/testing/Internals.h (186400 => 186401)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/Source/WebCore/testing/Internals.h        2015-07-07 05:37:38 UTC (rev 186400)
+++ releases/WebKitGTK/webkit-2.8/Source/WebCore/testing/Internals.h        2015-07-07 05:56:18 UTC (rev 186401)
</span><span class="lines">@@ -286,6 +286,7 @@
</span><span class="cx"> void stopTrackingRepaints(ExceptionCode&);
</span><span class="cx"> void updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks(ExceptionCode&);
</span><span class="cx"> void updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks(Node*, ExceptionCode&);
</span><ins>+ unsigned layoutCount() const;
</ins><span class="cx">
</span><span class="cx"> PassRefPtr<ArrayBuffer> serializeObject(PassRefPtr<SerializedScriptValue>) const;
</span><span class="cx"> PassRefPtr<SerializedScriptValue> deserializeBuffer(PassRefPtr<ArrayBuffer>) const;
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit28SourceWebCoretestingInternalsidl"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/Source/WebCore/testing/Internals.idl (186400 => 186401)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/Source/WebCore/testing/Internals.idl        2015-07-07 05:37:38 UTC (rev 186400)
+++ releases/WebKitGTK/webkit-2.8/Source/WebCore/testing/Internals.idl        2015-07-07 05:56:18 UTC (rev 186401)
</span><span class="lines">@@ -258,6 +258,8 @@
</span><span class="cx"> // specified without security checks. Unspecified means this document.
</span><span class="cx"> [RaisesException] void updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks(optional Node node);
</span><span class="cx">
</span><ins>+ readonly attribute unsigned long layoutCount;
+
</ins><span class="cx"> // Returns a string with information about the mouse cursor used at the specified client location.
</span><span class="cx"> [RaisesException] DOMString getCurrentCursorInfo();
</span><span class="cx">
</span></span></pre>
</div>
</div>
</body>
</html>