Title: [111883] trunk
Revision
111883
Author
[email protected]
Date
2012-03-23 11:30:01 -0700 (Fri, 23 Mar 2012)

Log Message

CSS3 calc: image sizing works with mixed percentage/absolute
https://bugs.webkit.org/show_bug.cgi?id=82017

Reviewed by Ojan Vafai.

Source/WebCore:

Test: css3/calc/img-size-expected.html

* rendering/RenderBox.cpp:
(WebCore::RenderBox::computeReplacedLogicalWidthUsing):
(WebCore::RenderBox::computeReplacedLogicalHeightUsing):

LayoutTests:

Test is now expected to match.

* css3/calc/img-size-expected.html: Renamed from LayoutTests/css3/calc/img-size-expected-mismatch.html.

Modified Paths

Added Paths

Removed Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (111882 => 111883)


--- trunk/LayoutTests/ChangeLog	2012-03-23 18:27:30 UTC (rev 111882)
+++ trunk/LayoutTests/ChangeLog	2012-03-23 18:30:01 UTC (rev 111883)
@@ -1,3 +1,14 @@
+2012-03-23  Mike Lawther  <[email protected]>
+
+        CSS3 calc: image sizing works with mixed percentage/absolute
+        https://bugs.webkit.org/show_bug.cgi?id=82017
+
+        Reviewed by Ojan Vafai.
+
+        Test is now expected to match.
+
+        * css3/calc/img-size-expected.html: Renamed from LayoutTests/css3/calc/img-size-expected-mismatch.html.
+
 2012-03-23  Julien Chaffraix  <[email protected]>
 
         REGRESSION(107971): Google Voice contact list is broken in WebKit due to badly allocating the extra height

Deleted: trunk/LayoutTests/css3/calc/img-size-expected-mismatch.html (111882 => 111883)


--- trunk/LayoutTests/css3/calc/img-size-expected-mismatch.html	2012-03-23 18:27:30 UTC (rev 111882)
+++ trunk/LayoutTests/css3/calc/img-size-expected-mismatch.html	2012-03-23 18:30:01 UTC (rev 111883)
@@ -1,15 +0,0 @@
-<style>
-    img      { margin-top: 10px;}
-    .control { width: 50%; }
-    .pixels  { width: 100px; }
-    .percent { width: 50%; }
-    .both    { width: 100px; }
-</style>
-
-The images below must appear identical.
-<div style="width:200px;">
-    <img class="control" src=""
-    <img class="pixels"  src=""
-    <img class="percent" src=""
-    <img class="both"    src=""
-</div>

Copied: trunk/LayoutTests/css3/calc/img-size-expected.html (from rev 111882, trunk/LayoutTests/css3/calc/img-size-expected-mismatch.html) (0 => 111883)


--- trunk/LayoutTests/css3/calc/img-size-expected.html	                        (rev 0)
+++ trunk/LayoutTests/css3/calc/img-size-expected.html	2012-03-23 18:30:01 UTC (rev 111883)
@@ -0,0 +1,15 @@
+<style>
+    img      { margin-top: 10px;}
+    .control { width: 50%; }
+    .pixels  { width: 100px; }
+    .percent { width: 50%; }
+    .both    { width: 100px; }
+</style>
+
+The images below must appear identical.
+<div style="width:200px;">
+    <img class="control" src=""
+    <img class="pixels"  src=""
+    <img class="percent" src=""
+    <img class="both"    src=""
+</div>

Modified: trunk/Source/WebCore/ChangeLog (111882 => 111883)


--- trunk/Source/WebCore/ChangeLog	2012-03-23 18:27:30 UTC (rev 111882)
+++ trunk/Source/WebCore/ChangeLog	2012-03-23 18:30:01 UTC (rev 111883)
@@ -1,3 +1,16 @@
+2012-03-23  Mike Lawther  <[email protected]>
+
+        CSS3 calc: image sizing works with mixed percentage/absolute
+        https://bugs.webkit.org/show_bug.cgi?id=82017
+
+        Reviewed by Ojan Vafai.
+
+        Test: css3/calc/img-size-expected.html
+
+        * rendering/RenderBox.cpp:
+        (WebCore::RenderBox::computeReplacedLogicalWidthUsing):
+        (WebCore::RenderBox::computeReplacedLogicalHeightUsing):
+
 2012-03-23  Julien Chaffraix  <[email protected]>
 
         REGRESSION(107971): Google Voice contact list is broken in WebKit due to badly allocating the extra height

Modified: trunk/Source/WebCore/rendering/RenderBox.cpp (111882 => 111883)


--- trunk/Source/WebCore/rendering/RenderBox.cpp	2012-03-23 18:27:30 UTC (rev 111882)
+++ trunk/Source/WebCore/rendering/RenderBox.cpp	2012-03-23 18:30:01 UTC (rev 111883)
@@ -2274,7 +2274,8 @@
     switch (logicalWidth.type()) {
         case Fixed:
             return computeContentBoxLogicalWidth(logicalWidth.value());
-        case Percent: {
+        case Percent: 
+        case Calculated: {
             // FIXME: containingBlockLogicalWidthForContent() is wrong if the replaced element's block-flow is perpendicular to the
             // containing block's block-flow.
             // https://bugs.webkit.org/show_bug.cgi?id=46496
@@ -2306,6 +2307,7 @@
         case Fixed:
             return computeContentBoxLogicalHeight(logicalHeight.value());
         case Percent:
+        case Calculated:
         {
             RenderObject* cb = isPositioned() ? container() : containingBlock();
             while (cb->isAnonymous()) {
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to