Title: [121026] trunk
Revision
121026
Author
[email protected]
Date
2012-06-22 08:20:50 -0700 (Fri, 22 Jun 2012)

Log Message

-webkit-flex-flow shouldn't be an enumerable property of the computed style
https://bugs.webkit.org/show_bug.cgi?id=89698

Reviewed by Ojan Vafai.

Source/WebCore:

flex-flow is a shorthand for flex-direction and flex-wrap:
http://dev.w3.org/csswg/css3-flexbox/#flex-flow-property
Shorthand properties should not be enumerable in the computed style, although you can still
get the value from the computed style.

Tests: css3/flexbox/css-properties.html: New test case added.

* css/CSSComputedStyleDeclaration.cpp:
(WebCore):

LayoutTests:

* css3/flexbox/css-properties-expected.txt:
* css3/flexbox/css-properties.html:
* fast/css/getComputedStyle/computed-style-expected.txt:
* fast/css/getComputedStyle/computed-style-without-renderer-expected.txt:
* fast/css/getComputedStyle/resources/property-names.js:
* svg/css/getComputedStyle-basic-expected.txt:

Modified Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (121025 => 121026)


--- trunk/LayoutTests/ChangeLog	2012-06-22 15:18:46 UTC (rev 121025)
+++ trunk/LayoutTests/ChangeLog	2012-06-22 15:20:50 UTC (rev 121026)
@@ -1,3 +1,17 @@
+2012-06-22  Tony Chang  <[email protected]>
+
+        -webkit-flex-flow shouldn't be an enumerable property of the computed style
+        https://bugs.webkit.org/show_bug.cgi?id=89698
+
+        Reviewed by Ojan Vafai.
+
+        * css3/flexbox/css-properties-expected.txt:
+        * css3/flexbox/css-properties.html:
+        * fast/css/getComputedStyle/computed-style-expected.txt:
+        * fast/css/getComputedStyle/computed-style-without-renderer-expected.txt:
+        * fast/css/getComputedStyle/resources/property-names.js:
+        * svg/css/getComputedStyle-basic-expected.txt:
+
 2012-06-22  Ádám Kallai  <[email protected]>
 
         [Qt] Unreviewed gardening. Skip failing test after r121019.

Modified: trunk/LayoutTests/css3/flexbox/css-properties-expected.txt (121025 => 121026)


--- trunk/LayoutTests/css3/flexbox/css-properties-expected.txt	2012-06-22 15:18:46 UTC (rev 121025)
+++ trunk/LayoutTests/css3/flexbox/css-properties-expected.txt	2012-06-22 15:20:50 UTC (rev 121026)
@@ -190,6 +190,7 @@
 PASS window.getComputedStyle(flexbox, null).webkitFlexFlow is "column wrap"
 PASS flexbox.style.webkitFlexFlow is "row-reverse wrap-reverse"
 PASS window.getComputedStyle(flexbox, null).webkitFlexFlow is "row-reverse wrap-reverse"
+PASS foundFlexFlow is false
 PASS flexbox.style.webkitAlignContent is ""
 PASS window.getComputedStyle(flexbox, null).webkitAlignContent is "stretch"
 PASS flexbox.style.webkitAlignContent is "flex-start"

Modified: trunk/LayoutTests/css3/flexbox/css-properties.html (121025 => 121026)


--- trunk/LayoutTests/css3/flexbox/css-properties.html	2012-06-22 15:18:46 UTC (rev 121025)
+++ trunk/LayoutTests/css3/flexbox/css-properties.html	2012-06-22 15:20:50 UTC (rev 121026)
@@ -259,6 +259,15 @@
 shouldBeEqualToString('flexbox.style.webkitFlexFlow', 'row-reverse wrap-reverse');
 shouldBeEqualToString('window.getComputedStyle(flexbox, null).webkitFlexFlow', 'row-reverse wrap-reverse');
 
+// -webkit-flex-flow is a shorthand, so it shouldn't show up as a computed property.
+var computedStyle = getComputedStyle(flexbox);
+var foundFlexFlow = false;
+for (var i = 0; i < computedStyle.length; ++i) {
+    if (computedStyle[i] == 'webkitFlexFlow')
+        foundFlexFlow = true;
+}
+shouldBeFalse('foundFlexFlow');
+
 // The initial value is 'stretch'.
 shouldBeEqualToString('flexbox.style.webkitAlignContent', '');
 shouldBeEqualToString('window.getComputedStyle(flexbox, null).webkitAlignContent', 'stretch');

Modified: trunk/LayoutTests/fast/css/getComputedStyle/computed-style-expected.txt (121025 => 121026)


--- trunk/LayoutTests/fast/css/getComputedStyle/computed-style-expected.txt	2012-06-22 15:18:46 UTC (rev 121025)
+++ trunk/LayoutTests/fast/css/getComputedStyle/computed-style-expected.txt	2012-06-22 15:20:50 UTC (rev 121026)
@@ -148,7 +148,6 @@
 -webkit-align-self: stretch;
 -webkit-flex: 0 1 auto;
 -webkit-flex-direction: row;
--webkit-flex-flow: row none;
 -webkit-flex-wrap: none;
 -webkit-justify-content: flex-start;
 -webkit-font-kerning: auto;

Modified: trunk/LayoutTests/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt (121025 => 121026)


--- trunk/LayoutTests/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt	2012-06-22 15:18:46 UTC (rev 121025)
+++ trunk/LayoutTests/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt	2012-06-22 15:20:50 UTC (rev 121026)
@@ -147,7 +147,6 @@
 -webkit-align-self: stretch
 -webkit-flex: 0 1 auto
 -webkit-flex-direction: row
--webkit-flex-flow: row none
 -webkit-flex-wrap: none
 -webkit-justify-content: flex-start
 -webkit-font-kerning: auto

Modified: trunk/LayoutTests/fast/css/getComputedStyle/resources/property-names.js (121025 => 121026)


--- trunk/LayoutTests/fast/css/getComputedStyle/resources/property-names.js	2012-06-22 15:18:46 UTC (rev 121025)
+++ trunk/LayoutTests/fast/css/getComputedStyle/resources/property-names.js	2012-06-22 15:20:50 UTC (rev 121026)
@@ -46,7 +46,6 @@
     "-webkit-column-width": true,
     "-webkit-flex": true,
     "-webkit-flex-direction": true,
-    "-webkit-flex-flow": true,
     "-webkit-flex-wrap": true,
     "-webkit-font-kerning": true,
     "-webkit-font-smoothing": true,

Modified: trunk/LayoutTests/svg/css/getComputedStyle-basic-expected.txt (121025 => 121026)


--- trunk/LayoutTests/svg/css/getComputedStyle-basic-expected.txt	2012-06-22 15:18:46 UTC (rev 121025)
+++ trunk/LayoutTests/svg/css/getComputedStyle-basic-expected.txt	2012-06-22 15:20:50 UTC (rev 121026)
@@ -294,8 +294,6 @@
 rect: style.getPropertyCSSValue(-webkit-flex) : [object CSSValueList]
 rect: style.getPropertyValue(-webkit-flex-direction) : row
 rect: style.getPropertyCSSValue(-webkit-flex-direction) : [object CSSPrimitiveValue]
-rect: style.getPropertyValue(-webkit-flex-flow) : row none
-rect: style.getPropertyCSSValue(-webkit-flex-flow) : [object CSSValueList]
 rect: style.getPropertyValue(-webkit-flex-wrap) : none
 rect: style.getPropertyCSSValue(-webkit-flex-wrap) : [object CSSPrimitiveValue]
 rect: style.getPropertyValue(-webkit-justify-content) : flex-start
@@ -800,8 +798,6 @@
 g: style.getPropertyCSSValue(-webkit-flex) : [object CSSValueList]
 g: style.getPropertyValue(-webkit-flex-direction) : row
 g: style.getPropertyCSSValue(-webkit-flex-direction) : [object CSSPrimitiveValue]
-g: style.getPropertyValue(-webkit-flex-flow) : row none
-g: style.getPropertyCSSValue(-webkit-flex-flow) : [object CSSValueList]
 g: style.getPropertyValue(-webkit-flex-wrap) : none
 g: style.getPropertyCSSValue(-webkit-flex-wrap) : [object CSSPrimitiveValue]
 g: style.getPropertyValue(-webkit-justify-content) : flex-start

Modified: trunk/Source/WebCore/ChangeLog (121025 => 121026)


--- trunk/Source/WebCore/ChangeLog	2012-06-22 15:18:46 UTC (rev 121025)
+++ trunk/Source/WebCore/ChangeLog	2012-06-22 15:20:50 UTC (rev 121026)
@@ -1,3 +1,20 @@
+2012-06-22  Tony Chang  <[email protected]>
+
+        -webkit-flex-flow shouldn't be an enumerable property of the computed style
+        https://bugs.webkit.org/show_bug.cgi?id=89698
+
+        Reviewed by Ojan Vafai.
+
+        flex-flow is a shorthand for flex-direction and flex-wrap:
+        http://dev.w3.org/csswg/css3-flexbox/#flex-flow-property
+        Shorthand properties should not be enumerable in the computed style, although you can still
+        get the value from the computed style.
+
+        Tests: css3/flexbox/css-properties.html: New test case added.
+
+        * css/CSSComputedStyleDeclaration.cpp:
+        (WebCore):
+
 2012-06-22  Robert Kroeger  <[email protected]>
 
         Suppress horizontal conversion of PlatformWheelEvents when hasPreciseScrollingDeltas is true

Modified: trunk/Source/WebCore/css/CSSComputedStyleDeclaration.cpp (121025 => 121026)


--- trunk/Source/WebCore/css/CSSComputedStyleDeclaration.cpp	2012-06-22 15:18:46 UTC (rev 121025)
+++ trunk/Source/WebCore/css/CSSComputedStyleDeclaration.cpp	2012-06-22 15:20:50 UTC (rev 121026)
@@ -239,7 +239,6 @@
     CSSPropertyWebkitAlignSelf,
     CSSPropertyWebkitFlex,
     CSSPropertyWebkitFlexDirection,
-    CSSPropertyWebkitFlexFlow,
     CSSPropertyWebkitFlexWrap,
     CSSPropertyWebkitJustifyContent,
 #endif
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to