Title: [144706] trunk
- Revision
- 144706
- Author
- commit-qu...@webkit.org
- Date
- 2013-03-04 18:46:44 -0800 (Mon, 04 Mar 2013)
Log Message
REGRESSION (r143643): Buttons containing floats render differently
https://bugs.webkit.org/show_bug.cgi?id=110933
Patch by Christian Biesinger <cbiesin...@chromium.org> on 2013-03-04
Reviewed by Ojan Vafai.
Source/WebCore:
Test: fast/forms/button-with-float.html
* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::expandsToEncloseOverhangingFloats):
Also include new flexbox as a renderer that needs to enclose
overhanging floats. Flex boxes establish a block formatting context,
so they need to contain floats:
http://dev.w3.org/csswg/css3-flexbox/#flex-items
LayoutTests:
* css3/flexbox/float-inside-flexitem-expected.html: Added.
* css3/flexbox/float-inside-flexitem.html: Added.
* fast/forms/button-with-float-expected.html: Added.
* fast/forms/button-with-float.html: Added.
Modified Paths
Added Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (144705 => 144706)
--- trunk/LayoutTests/ChangeLog 2013-03-05 02:34:27 UTC (rev 144705)
+++ trunk/LayoutTests/ChangeLog 2013-03-05 02:46:44 UTC (rev 144706)
@@ -1,3 +1,15 @@
+2013-03-04 Christian Biesinger <cbiesin...@chromium.org>
+
+ REGRESSION (r143643): Buttons containing floats render differently
+ https://bugs.webkit.org/show_bug.cgi?id=110933
+
+ Reviewed by Ojan Vafai.
+
+ * css3/flexbox/float-inside-flexitem-expected.html: Added.
+ * css3/flexbox/float-inside-flexitem.html: Added.
+ * fast/forms/button-with-float-expected.html: Added.
+ * fast/forms/button-with-float.html: Added.
+
2013-03-04 Rafael Weinstein <rafa...@chromium.org>
Unreviewed, rolling out r144595.
Added: trunk/LayoutTests/css3/flexbox/float-inside-flexitem-expected.html (0 => 144706)
--- trunk/LayoutTests/css3/flexbox/float-inside-flexitem-expected.html (rev 0)
+++ trunk/LayoutTests/css3/flexbox/float-inside-flexitem-expected.html 2013-03-05 02:46:44 UTC (rev 144706)
@@ -0,0 +1,51 @@
+<!DOCTYPE html>
+<head>
+<style>
+ .container {
+ position: relative;
+ -webkit-appearance: none;
+ -moz-appearance: none;
+ border: 1px solid black;
+ padding: 0;
+ background-color: buttonface;
+ float: left;
+ margin: 2px;
+ }
+
+ .margin {
+ margin: 5px 10px 5px 5px;
+ }
+ .sized {
+ width: 50px;
+ height: 50px;
+ }
+ .pink {
+ background-color: pink;
+ }
+ .float {
+ float: left;
+ }
+ .line {
+ height: 2px;
+ border-top: solid 1px #fff;
+ background: #00f;
+
+ position: absolute;
+ width: 50px;
+ bottom: 5px;
+ left: 5px;
+ }
+</style>
+</head>
+<body>
+ You should see an almost-square grey rectangle containing a pink square with a blue line below it.
+ There should be no pink below the blue line.
+<hr>
+<div class="container">
+ <div class="margin sized float">
+ <div class="sized">
+ <div class="sized pink">
+ <div class="line"></div>
+ </div>
+ </div>
+</div>
Added: trunk/LayoutTests/css3/flexbox/float-inside-flexitem.html (0 => 144706)
--- trunk/LayoutTests/css3/flexbox/float-inside-flexitem.html (rev 0)
+++ trunk/LayoutTests/css3/flexbox/float-inside-flexitem.html 2013-03-05 02:46:44 UTC (rev 144706)
@@ -0,0 +1,54 @@
+<!DOCTYPE html>
+<head>
+<link href="" rel="stylesheet">
+<style>
+ .container {
+ position: relative;
+ -webkit-appearance: none;
+ -moz-appearance: none;
+ border: 1px solid black;
+ padding: 0;
+ background-color: buttonface;
+ float: left;
+ margin: 2px;
+ }
+
+ .margin {
+ margin: 5px 10px 5px 5px;
+ }
+ .sized {
+ width: 50px;
+ height: 50px;
+ }
+ .pink {
+ background-color: pink;
+ }
+ .float {
+ float: left;
+ }
+ .line {
+ height: 2px;
+ border-top: solid 1px #fff;
+ background: #00f;
+
+ position: absolute;
+ width: 50px;
+ bottom: 5px;
+ left: 5px;
+ }
+</style>
+</head>
+<body>
+ You should see an almost-square grey rectangle containing a pink square with a blue line below it.
+ There should be no pink below the blue line.
+<hr>
+<div class="container flexbox">
+ <div>
+ <div class="margin sized float">
+ <div class="sized">
+ <div class="sized pink">
+ <div class="line"></div>
+ </div>
+ </div>
+ </div>
+</div>
Added: trunk/LayoutTests/fast/forms/button-with-float-expected.html (0 => 144706)
--- trunk/LayoutTests/fast/forms/button-with-float-expected.html (rev 0)
+++ trunk/LayoutTests/fast/forms/button-with-float-expected.html 2013-03-05 02:46:44 UTC (rev 144706)
@@ -0,0 +1,50 @@
+<!DOCTYPE html>
+<head>
+<style>
+ .container {
+ position: relative;
+ -webkit-appearance: none;
+ border: 1px solid black;
+ padding: 0;
+ background-color: buttonface;
+ float: left;
+ margin: 2px;
+ }
+
+ .margin {
+ margin: 5px 10px 5px 5px;
+ }
+ .sized {
+ width: 50px;
+ height: 50px;
+ }
+ .pink {
+ background-color: pink;
+ }
+ .float {
+ float: left;
+ }
+ .line {
+ height: 2px;
+ border-top: solid 1px #fff;
+ background: #00f;
+
+ position: absolute;
+ width: 50px;
+ bottom: 5px;
+ left: 5px;
+ }
+</style>
+</head>
+<body>
+ You should see an almost-square grey rectangle containing a pink square with a blue line below it.
+ There should be no pink below the blue line.
+<hr>
+<div class="container">
+ <div class="margin sized float">
+ <div class="sized">
+ <div class="sized pink">
+ <div class="line"></div>
+ </div>
+ </div>
+</div>
Added: trunk/LayoutTests/fast/forms/button-with-float.html (0 => 144706)
--- trunk/LayoutTests/fast/forms/button-with-float.html (rev 0)
+++ trunk/LayoutTests/fast/forms/button-with-float.html 2013-03-05 02:46:44 UTC (rev 144706)
@@ -0,0 +1,47 @@
+<!DOCTYPE html>
+<head>
+<style>
+ button {
+ position: relative;
+ -webkit-appearance: none;
+ border: 1px solid black;
+ padding: 0;
+ }
+
+ .margin {
+ margin: 5px 10px 5px 5px;
+ }
+ .sized {
+ width: 50px;
+ height: 50px;
+ }
+ .pink {
+ background-color: pink;
+ }
+ .float {
+ float: left;
+ }
+ .line {
+ height: 2px;
+ border-top: solid 1px #fff;
+ background: #00f;
+
+ position: absolute;
+ width: 50px;
+ bottom: 5px;
+ left: 5px;
+ }
+</style>
+</head>
+<body>
+ You should see an almost-square grey rectangle containing a pink square with a blue line below it.
+ There should be no pink below the blue line.
+<hr>
+<button>
+ <div class="margin sized float">
+ <div class="sized">
+ <div class="sized pink">
+ <div class="line"></div>
+ </div>
+ </div>
+</button>
Modified: trunk/Source/WebCore/ChangeLog (144705 => 144706)
--- trunk/Source/WebCore/ChangeLog 2013-03-05 02:34:27 UTC (rev 144705)
+++ trunk/Source/WebCore/ChangeLog 2013-03-05 02:46:44 UTC (rev 144706)
@@ -1,3 +1,19 @@
+2013-03-04 Christian Biesinger <cbiesin...@chromium.org>
+
+ REGRESSION (r143643): Buttons containing floats render differently
+ https://bugs.webkit.org/show_bug.cgi?id=110933
+
+ Reviewed by Ojan Vafai.
+
+ Test: fast/forms/button-with-float.html
+
+ * rendering/RenderBlock.cpp:
+ (WebCore::RenderBlock::expandsToEncloseOverhangingFloats):
+ Also include new flexbox as a renderer that needs to enclose
+ overhanging floats. Flex boxes establish a block formatting context,
+ so they need to contain floats:
+ http://dev.w3.org/csswg/css3-flexbox/#flex-items
+
2013-03-04 Chris Fleizach <cfleiz...@apple.com>
Support WebSpeech - Speech Synthesis
Modified: trunk/Source/WebCore/rendering/RenderBlock.cpp (144705 => 144706)
--- trunk/Source/WebCore/rendering/RenderBlock.cpp 2013-03-05 02:34:27 UTC (rev 144705)
+++ trunk/Source/WebCore/rendering/RenderBlock.cpp 2013-03-05 02:46:44 UTC (rev 144706)
@@ -1797,7 +1797,7 @@
bool RenderBlock::expandsToEncloseOverhangingFloats() const
{
- return isInlineBlockOrInlineTable() || isFloatingOrOutOfFlowPositioned() || hasOverflowClip() || (parent() && parent()->isDeprecatedFlexibleBox())
+ return isInlineBlockOrInlineTable() || isFloatingOrOutOfFlowPositioned() || hasOverflowClip() || (parent() && parent()->isFlexibleBoxIncludingDeprecated())
|| hasColumns() || isTableCell() || isTableCaption() || isFieldset() || isWritingModeRoot() || isRoot();
}
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes