Title: [112114] trunk
- Revision
- 112114
- Author
- [email protected]
- Date
- 2012-03-26 09:52:01 -0700 (Mon, 26 Mar 2012)
Log Message
REGRESSION (r110065-r110080): fast/forms/placeholder-set-attribute.html is failing intermittently because WebKit fails to repaint after setting the placeholder attribute
https://bugs.webkit.org/show_bug.cgi?id=81802
Reviewed by Dan Bernstein.
Source/WebCore:
Covered by fast/forms/placeholder-set-attribute.html which should be less flaky.
Unfortunately no new test case as this bug requires a very specific set of conditions that I couldn't reproduce deterministically.
This is a regression from r110072: RenderTextControlSingleLine would rely on the placeholder's RenderLayer to properly repaint during
the first layout as the placeholder has overflow: hidden set. r110072 removed the layer in this case and thus we miss a repaint.
* rendering/RenderTextControlSingleLine.cpp:
(WebCore::RenderTextControlSingleLine::layout):
For our first layout, we need to make sure our placeholder is painted. layoutBlockChild has a very similar logic to force repaint
on a first layout. We don't hit this logic as the placeholder is explicitly skipped in RenderTextControl::layoutSpecialExcludedChild.
LayoutTests:
* platform/mac/Skipped: Unskip the test on Mac. The other platforms are either
skipping it for other reasons or did not have a specific entry for the flakiness.
Modified Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (112113 => 112114)
--- trunk/LayoutTests/ChangeLog 2012-03-26 16:46:17 UTC (rev 112113)
+++ trunk/LayoutTests/ChangeLog 2012-03-26 16:52:01 UTC (rev 112114)
@@ -1,5 +1,15 @@
2012-03-26 Julien Chaffraix <[email protected]>
+ REGRESSION (r110065-r110080): fast/forms/placeholder-set-attribute.html is failing intermittently because WebKit fails to repaint after setting the placeholder attribute
+ https://bugs.webkit.org/show_bug.cgi?id=81802
+
+ Reviewed by Dan Bernstein.
+
+ * platform/mac/Skipped: Unskip the test on Mac. The other platforms are either
+ skipping it for other reasons or did not have a specific entry for the flakiness.
+
+2012-03-26 Julien Chaffraix <[email protected]>
+
REGRESSION(r110072): fast/forms/textfield-overflow.html is failing
https://bugs.webkit.org/show_bug.cgi?id=80531
Modified: trunk/LayoutTests/platform/mac/Skipped (112113 => 112114)
--- trunk/LayoutTests/platform/mac/Skipped 2012-03-26 16:46:17 UTC (rev 112113)
+++ trunk/LayoutTests/platform/mac/Skipped 2012-03-26 16:52:01 UTC (rev 112114)
@@ -604,10 +604,6 @@
# Allowed to regress to fix a crash.
fast/inline/continuation-outlines-with-layers.html
-# https://bugs.webkit.org/show_bug.cgi?id=81802 rdar://problem/11091412
-# fast/forms/placeholder-set-attribute.html is failing intermittently because WebKit fails to repaint after setting the placeholder attribute
-fast/forms/placeholder-set-attribute.html
-
# Not possible to set UA string for media requests with all Mac media engines.
http/tests/media/video-useragent.html
Modified: trunk/Source/WebCore/ChangeLog (112113 => 112114)
--- trunk/Source/WebCore/ChangeLog 2012-03-26 16:46:17 UTC (rev 112113)
+++ trunk/Source/WebCore/ChangeLog 2012-03-26 16:52:01 UTC (rev 112114)
@@ -1,5 +1,24 @@
2012-03-26 Julien Chaffraix <[email protected]>
+ REGRESSION (r110065-r110080): fast/forms/placeholder-set-attribute.html is failing intermittently because WebKit fails to repaint after setting the placeholder attribute
+ https://bugs.webkit.org/show_bug.cgi?id=81802
+
+ Reviewed by Dan Bernstein.
+
+ Covered by fast/forms/placeholder-set-attribute.html which should be less flaky.
+
+ Unfortunately no new test case as this bug requires a very specific set of conditions that I couldn't reproduce deterministically.
+
+ This is a regression from r110072: RenderTextControlSingleLine would rely on the placeholder's RenderLayer to properly repaint during
+ the first layout as the placeholder has overflow: hidden set. r110072 removed the layer in this case and thus we miss a repaint.
+
+ * rendering/RenderTextControlSingleLine.cpp:
+ (WebCore::RenderTextControlSingleLine::layout):
+ For our first layout, we need to make sure our placeholder is painted. layoutBlockChild has a very similar logic to force repaint
+ on a first layout. We don't hit this logic as the placeholder is explicitly skipped in RenderTextControl::layoutSpecialExcludedChild.
+
+2012-03-26 Julien Chaffraix <[email protected]>
+
REGRESSION(r110072): fast/forms/textfield-overflow.html is failing
https://bugs.webkit.org/show_bug.cgi?id=80531
Modified: trunk/Source/WebCore/rendering/RenderTextControlSingleLine.cpp (112113 => 112114)
--- trunk/Source/WebCore/rendering/RenderTextControlSingleLine.cpp 2012-03-26 16:46:17 UTC (rev 112113)
+++ trunk/Source/WebCore/rendering/RenderTextControlSingleLine.cpp 2012-03-26 16:52:01 UTC (rev 112114)
@@ -279,6 +279,7 @@
if (RenderBox* placeholderBox = placeholderElement ? placeholderElement->renderBox() : 0) {
placeholderBox->style()->setWidth(Length(innerTextRenderer->width() - placeholderBox->borderAndPaddingWidth(), Fixed));
placeholderBox->style()->setHeight(Length(innerTextRenderer->height() - placeholderBox->borderAndPaddingHeight(), Fixed));
+ bool placeholderBoxHadLayout = placeholderBox->everHadLayout();
placeholderBox->layoutIfNeeded();
LayoutPoint textOffset = innerTextRenderer->location();
if (innerBlockElement() && innerBlockElement()->renderBox())
@@ -286,6 +287,12 @@
if (containerRenderer)
textOffset += toLayoutSize(containerRenderer->location());
placeholderBox->setLocation(textOffset);
+
+ if (!placeholderBoxHadLayout && placeholderBox->checkForRepaintDuringLayout()) {
+ // This assumes a shadow tree without floats. If floats are added, the
+ // logic should be shared with RenderBlock::layoutBlockChild.
+ placeholderBox->repaint();
+ }
}
}
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes