Changeset 113208 in webkit


Ignore:
Timestamp:
Apr 4, 2012 10:13:16 AM (12 years ago)
Author:
tony@chromium.org
Message:

Remove flex function css parsing
https://bugs.webkit.org/show_bug.cgi?id=83083

Reviewed by Ojan Vafai.

Source/WebCore:

The flexbox spec switched from using a flex() function on the width
and height to a css property. Now that the -webkit-flex: has been
implemented, we can remove the flex() function code.

No new tests. Removing an old test that used to test the flex() function.

  • CMakeLists.txt:
  • GNUmakefile.list.am:
  • Target.pri:
  • WebCore.gypi:
  • WebCore.vcproj/WebCore.vcproj:
  • WebCore.xcodeproj/project.pbxproj:
  • css/CSSAllInOne.cpp:
  • css/CSSFlexValue.cpp: Removed.
  • css/CSSFlexValue.h: Removed.
  • css/CSSParser.cpp:

(WebCore::CSSParser::parseValue):
(WebCore::CSSParser::parseFlex):

  • css/CSSParser.h:

(WebCore):

  • css/CSSStyleApplyProperty.cpp:

(WebCore::ApplyPropertyLength::applyValue):
(WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):

  • css/CSSValue.cpp:

(WebCore::CSSValue::cssText):
(WebCore::CSSValue::destroy):

  • css/CSSValue.h:
  • rendering/style/RenderStyle.h:
  • rendering/style/StyleFlexibleBoxData.cpp:

(WebCore::StyleFlexibleBoxData::StyleFlexibleBoxData):
(WebCore::StyleFlexibleBoxData::operator==):

  • rendering/style/StyleFlexibleBoxData.h:

LayoutTests:

Remove test of -webkit-flex() function.

  • css3/flexbox/flex-parsing-expected.txt: Removed.
  • css3/flexbox/flex-parsing.html: Removed.
  • css3/flexbox/script-tests/flex-parsing.js: Removed.
Location:
trunk
Files:
5 deleted
17 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r113207 r113208  
     12012-04-04  Tony Chang  <tony@chromium.org>
     2
     3        Remove flex function css parsing
     4        https://bugs.webkit.org/show_bug.cgi?id=83083
     5
     6        Reviewed by Ojan Vafai.
     7
     8        Remove test of -webkit-flex() function.
     9
     10        * css3/flexbox/flex-parsing-expected.txt: Removed.
     11        * css3/flexbox/flex-parsing.html: Removed.
     12        * css3/flexbox/script-tests/flex-parsing.js: Removed.
     13
    1142012-04-04  Dimitri Glazkov  <dglazkov@chromium.org>
    215
  • trunk/Source/WebCore/CMakeLists.txt

    r113109 r113208  
    457457    css/CSSCrossfadeValue.cpp
    458458    css/CSSCursorImageValue.cpp
    459     css/CSSFlexValue.cpp
    460459    css/CSSFontFace.cpp
    461460    css/CSSFontFaceRule.cpp
  • trunk/Source/WebCore/ChangeLog

    r113204 r113208  
     12012-04-04  Tony Chang  <tony@chromium.org>
     2
     3        Remove flex function css parsing
     4        https://bugs.webkit.org/show_bug.cgi?id=83083
     5
     6        Reviewed by Ojan Vafai.
     7
     8        The flexbox spec switched from using a flex() function on the width
     9        and height to a css property. Now that the -webkit-flex: has been
     10        implemented, we can remove the flex() function code.
     11
     12        No new tests. Removing an old test that used to test the flex() function.
     13
     14        * CMakeLists.txt:
     15        * GNUmakefile.list.am:
     16        * Target.pri:
     17        * WebCore.gypi:
     18        * WebCore.vcproj/WebCore.vcproj:
     19        * WebCore.xcodeproj/project.pbxproj:
     20        * css/CSSAllInOne.cpp:
     21        * css/CSSFlexValue.cpp: Removed.
     22        * css/CSSFlexValue.h: Removed.
     23        * css/CSSParser.cpp:
     24        (WebCore::CSSParser::parseValue):
     25        (WebCore::CSSParser::parseFlex):
     26        * css/CSSParser.h:
     27        (WebCore):
     28        * css/CSSStyleApplyProperty.cpp:
     29        (WebCore::ApplyPropertyLength::applyValue):
     30        (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):
     31        * css/CSSValue.cpp:
     32        (WebCore::CSSValue::cssText):
     33        (WebCore::CSSValue::destroy):
     34        * css/CSSValue.h:
     35        * rendering/style/RenderStyle.h:
     36        * rendering/style/StyleFlexibleBoxData.cpp:
     37        (WebCore::StyleFlexibleBoxData::StyleFlexibleBoxData):
     38        (WebCore::StyleFlexibleBoxData::operator==):
     39        * rendering/style/StyleFlexibleBoxData.h:
     40
    1412012-04-04  Kausalya Madhusudhanan  <kmadhusu@chromium.org>
    242
  • trunk/Source/WebCore/GNUmakefile.list.am

    r113109 r113208  
    15751575        Source/WebCore/css/CSSCursorImageValue.cpp \
    15761576        Source/WebCore/css/CSSCursorImageValue.h \
    1577         Source/WebCore/css/CSSFlexValue.cpp \
    1578         Source/WebCore/css/CSSFlexValue.h \
    15791577        Source/WebCore/css/CSSFontFace.cpp \
    15801578        Source/WebCore/css/CSSFontFace.h \
  • trunk/Source/WebCore/Target.pri

    r113111 r113208  
    432432    css/CSSCrossfadeValue.cpp \
    433433    css/CSSCursorImageValue.cpp \
    434     css/CSSFlexValue.cpp \
    435434    css/CSSFontFace.cpp \
    436435    css/CSSFontFaceRule.cpp \
     
    15771576    css/CSSCrossfadeValue.h \
    15781577    css/CSSCursorImageValue.h \
    1579     css/CSSFlexValue.h \
    15801578    css/CSSFontFace.h \
    15811579    css/CSSFontFaceRule.h \
  • trunk/Source/WebCore/WebCore.gypi

    r113166 r113208  
    23792379            'css/CSSCrossfadeValue.h',
    23802380            'css/CSSCursorImageValue.cpp',
    2381             'css/CSSFlexValue.cpp',
    2382             'css/CSSFlexValue.h',
    23832381            'css/CSSFontFace.cpp',
    23842382            'css/CSSFontFace.h',
  • trunk/Source/WebCore/WebCore.vcproj/WebCore.vcproj

    r113109 r113208  
    3425934259                        </File>
    3426034260                        <File
    34261                                 RelativePath="..\css\CSSFlexValue.cpp"
    34262                                 >
    34263                                 <FileConfiguration
    34264                                         Name="Debug|Win32"
    34265                                         ExcludedFromBuild="true"
    34266                                         >
    34267                                         <Tool
    34268                                                 Name="VCCLCompilerTool"
    34269                                         />
    34270                                 </FileConfiguration>
    34271                                 <FileConfiguration
    34272                                         Name="Release|Win32"
    34273                                         ExcludedFromBuild="true"
    34274                                         >
    34275                                         <Tool
    34276                                                 Name="VCCLCompilerTool"
    34277                                         />
    34278                                 </FileConfiguration>
    34279                                 <FileConfiguration
    34280                                         Name="Debug_Cairo_CFLite|Win32"
    34281                                         ExcludedFromBuild="true"
    34282                                         >
    34283                                         <Tool
    34284                                                 Name="VCCLCompilerTool"
    34285                                         />
    34286                                 </FileConfiguration>
    34287                                 <FileConfiguration
    34288                                         Name="Release_Cairo_CFLite|Win32"
    34289                                         ExcludedFromBuild="true"
    34290                                         >
    34291                                         <Tool
    34292                                                 Name="VCCLCompilerTool"
    34293                                         />
    34294                                 </FileConfiguration>
    34295                                 <FileConfiguration
    34296                                         Name="Debug_All|Win32"
    34297                                         ExcludedFromBuild="true"
    34298                                         >
    34299                                         <Tool
    34300                                                 Name="VCCLCompilerTool"
    34301                                         />
    34302                                 </FileConfiguration>
    34303                                 <FileConfiguration
    34304                                         Name="Production|Win32"
    34305                                         ExcludedFromBuild="true"
    34306                                         >
    34307                                         <Tool
    34308                                                 Name="VCCLCompilerTool"
    34309                                         />
    34310                                 </FileConfiguration>
    34311                         </File>
    34312                         <File
    34313                                 RelativePath="..\css\CSSFlexValue.h"
    34314                                 >
    34315                         </File>
    34316                         <File
    3431734261                                RelativePath="..\css\CSSFontFace.cpp"
    3431834262                                >
  • trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj

    r113109 r113208  
    15701570                5317612213C516690026E454 /* StyleFlexibleBoxData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 5317612013C516690026E454 /* StyleFlexibleBoxData.cpp */; };
    15711571                5317612313C516690026E454 /* StyleFlexibleBoxData.h in Headers */ = {isa = PBXBuildFile; fileRef = 5317612113C516690026E454 /* StyleFlexibleBoxData.h */; settings = {ATTRIBUTES = (Private, ); }; };
    1572                 5325E4D713A6C88B00404A36 /* CSSFlexValue.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 5325E4D513A6C88B00404A36 /* CSSFlexValue.cpp */; };
    1573                 5325E4D813A6C88B00404A36 /* CSSFlexValue.h in Headers */ = {isa = PBXBuildFile; fileRef = 5325E4D613A6C88B00404A36 /* CSSFlexValue.h */; };
    15741572                53C8298D13D8D92700DE2DEB /* RenderFlexibleBox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 53C8298B13D8D92700DE2DEB /* RenderFlexibleBox.cpp */; };
    15751573                53C8298E13D8D92700DE2DEB /* RenderFlexibleBox.h in Headers */ = {isa = PBXBuildFile; fileRef = 53C8298C13D8D92700DE2DEB /* RenderFlexibleBox.h */; };
     
    85478545                5317612013C516690026E454 /* StyleFlexibleBoxData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = StyleFlexibleBoxData.cpp; path = style/StyleFlexibleBoxData.cpp; sourceTree = "<group>"; };
    85488546                5317612113C516690026E454 /* StyleFlexibleBoxData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = StyleFlexibleBoxData.h; path = style/StyleFlexibleBoxData.h; sourceTree = "<group>"; };
    8549                 5325E4D513A6C88B00404A36 /* CSSFlexValue.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CSSFlexValue.cpp; sourceTree = "<group>"; };
    8550                 5325E4D613A6C88B00404A36 /* CSSFlexValue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CSSFlexValue.h; sourceTree = "<group>"; };
    85518547                53C8298B13D8D92700DE2DEB /* RenderFlexibleBox.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = RenderFlexibleBox.cpp; sourceTree = "<group>"; };
    85528548                53C8298C13D8D92700DE2DEB /* RenderFlexibleBox.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RenderFlexibleBox.h; sourceTree = "<group>"; };
     
    2045920455                                AA0978ED0ABAA6E100874480 /* CSSCursorImageValue.cpp */,
    2046020456                                AA0978EE0ABAA6E100874480 /* CSSCursorImageValue.h */,
    20461                                 5325E4D513A6C88B00404A36 /* CSSFlexValue.cpp */,
    20462                                 5325E4D613A6C88B00404A36 /* CSSFlexValue.h */,
    2046320457                                BC64B4CD0CB4298A005F2B62 /* CSSFontFace.cpp */,
    2046420458                                BC64B4CE0CB4298A005F2B62 /* CSSFontFace.h */,
     
    2180821802                                2D8FEBDD143E3EF70072502B /* CSSCrossfadeValue.h in Headers */,
    2180921803                                AA21ECCD0ABF0FC6002B834C /* CSSCursorImageValue.h in Headers */,
    21810                                 5325E4D813A6C88B00404A36 /* CSSFlexValue.h in Headers */,
    2181121804                                BC64B4D60CB4298A005F2B62 /* CSSFontFace.h in Headers */,
    2181221805                                A80E6CFD0A1989CA007FB8C5 /* CSSFontFaceRule.h in Headers */,
     
    2528525278                                2D8FEBDC143E3EF70072502B /* CSSCrossfadeValue.cpp in Sources */,
    2528625279                                AA21ECCA0ABF0FBA002B834C /* CSSCursorImageValue.cpp in Sources */,
    25287                                 5325E4D713A6C88B00404A36 /* CSSFlexValue.cpp in Sources */,
    2528825280                                BC64B4D50CB4298A005F2B62 /* CSSFontFace.cpp in Sources */,
    2528925281                                A80E6CE70A1989CA007FB8C5 /* CSSFontFaceRule.cpp in Sources */,
  • trunk/Source/WebCore/css/CSSAllInOne.cpp

    r112914 r113208  
    3434#include "CSSCrossfadeValue.cpp"
    3535#include "CSSCursorImageValue.cpp"
    36 #include "CSSFlexValue.cpp"
    3736#include "CSSFontFace.cpp"
    3837#include "CSSFontFaceRule.cpp"
  • trunk/Source/WebCore/css/CSSParser.cpp

    r113139 r113208  
    3232#include "CSSCrossfadeValue.h"
    3333#include "CSSCursorImageValue.h"
    34 #include "CSSFlexValue.h"
    3534#include "CSSFontFaceRule.h"
    3635#include "CSSFontFaceSrcValue.h"
     
    17881787            // ### handle multilength case where we allow relative units
    17891788            validPrimitive = true;
    1790         else if (value->unit == CSSParserValue::Function) {
    1791             // FIXME: Remove -webkit-flex() handling once we finish implementing the -webkit-flex propery.
    1792             if (!equalIgnoringCase(value->function->name, "-webkit-flex(") || m_valueList->next())
    1793                 return false;
    1794             parsedValue = parseFlex(value->function->args.get());
    1795         }
    17961789        break;
    17971790
     
    20202013        break;
    20212014#endif
    2022     case CSSPropertyWebkitFlex: {
     2015    case CSSPropertyWebkitFlex:
    20232016        if (id == CSSValueNone)
    20242017            validPrimitive = true;
    2025         else if (RefPtr<CSSFlexValue> flexValue = parseFlex(m_valueList.get())) {
    2026             RefPtr<CSSValueList> flexList = CSSValueList::createSpaceSeparated();
    2027             flexList->append(cssValuePool()->createValue(flexValue->positiveFlex(), CSSPrimitiveValue::CSS_NUMBER));
    2028             flexList->append(cssValuePool()->createValue(flexValue->negativeFlex(), CSSPrimitiveValue::CSS_NUMBER));
    2029             flexList->append(flexValue->preferredSize());
    2030             parsedValue = flexList;
    2031         }
    2032         break;
    2033     }
     2018        else
     2019            parsedValue = parseFlex(m_valueList.get());
     2020        break;
    20342021    case CSSPropertyWebkitFlexOrder:
    20352022        if (validUnit(value, FInteger, CSSStrictMode)) {
     
    55175504}
    55185505
    5519 PassRefPtr<CSSFlexValue> CSSParser::parseFlex(CSSParserValueList* args)
     5506PassRefPtr<CSSValue> CSSParser::parseFlex(CSSParserValueList* args)
    55205507{
    55215508    if (!args || !args->size() || args->size() > 3)
     
    55555542        preferredSize = cssValuePool()->createValue(0, CSSPrimitiveValue::CSS_PX);
    55565543
    5557     RefPtr<CSSFlexValue> flex = CSSFlexValue::create(clampToFloat(positiveFlex), clampToFloat(negativeFlex), preferredSize);
     5544    RefPtr<CSSValueList> flex = CSSValueList::createSpaceSeparated();
     5545    flex->append(cssValuePool()->createValue(clampToFloat(positiveFlex), CSSPrimitiveValue::CSS_NUMBER));
     5546    flex->append(cssValuePool()->createValue(clampToFloat(negativeFlex), CSSPrimitiveValue::CSS_NUMBER));
     5547    flex->append(preferredSize);
    55585548    return flex;
    55595549}
  • trunk/Source/WebCore/css/CSSParser.h

    r113187 r113208  
    5454class CSSValue;
    5555class CSSValueList;
    56 class CSSFlexValue;
    5756class CSSWrapShape;
    5857class Document;
     
    189188    bool parseReflect(CSSPropertyID, bool important);
    190189
    191     PassRefPtr<CSSFlexValue> parseFlex(CSSParserValueList* args);
     190    PassRefPtr<CSSValue> parseFlex(CSSParserValueList* args);
    192191
    193192    // Image generators
  • trunk/Source/WebCore/css/CSSStyleApplyProperty.cpp

    r112968 r113208  
    2929#include "CSSCalculationValue.h"
    3030#include "CSSCursorImageValue.h"
    31 #include "CSSFlexValue.h"
    3231#include "CSSPrimitiveValueMappings.h"
    3332#include "CSSStyleSelector.h"
     
    337336enum LengthNone { NoneDisabled = 0, NoneEnabled };
    338337enum LengthUndefined { UndefinedDisabled = 0, UndefinedEnabled };
    339 enum LengthFlexDirection { FlexDirectionDisabled = 0, FlexWidth, FlexHeight };
    340338template <Length (RenderStyle::*getterFunction)() const,
    341339          void (RenderStyle::*setterFunction)(Length),
     
    345343          LengthMinIntrinsic minIntrinsicEnabled = MinIntrinsicDisabled,
    346344          LengthNone noneEnabled = NoneDisabled,
    347           LengthUndefined noneUndefined = UndefinedDisabled,
    348           LengthFlexDirection flexDirection = FlexDirectionDisabled>
     345          LengthUndefined noneUndefined = UndefinedDisabled>
    349346class ApplyPropertyLength {
    350347public:
     
    352349    static void applyValue(CSSStyleSelector* selector, CSSValue* value)
    353350    {
    354         float positiveFlex = 0;
    355         float negativeFlex = 0;
    356         if (!value->isPrimitiveValue()) {
    357             if (!flexDirection || !value->isFlexValue())
    358                 return;
    359 
    360             CSSFlexValue* flexValue = static_cast<CSSFlexValue*>(value);
    361             value = flexValue->preferredSize();
    362 
    363             positiveFlex = flexValue->positiveFlex();
    364             negativeFlex = flexValue->negativeFlex();
    365         }
    366 
    367         if (flexDirection == FlexWidth) {
    368             selector->style()->setFlexboxWidthPositiveFlex(positiveFlex);
    369             selector->style()->setFlexboxWidthNegativeFlex(negativeFlex);
    370         } else if (flexDirection == FlexHeight) {
    371             selector->style()->setFlexboxHeightPositiveFlex(positiveFlex);
    372             selector->style()->setFlexboxHeightNegativeFlex(negativeFlex);
    373         }
     351        if (!value->isPrimitiveValue())
     352            return;
    374353
    375354        CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
     
    18591838    setPropertyHandler(CSSPropertyFontVariant, ApplyPropertyFont<FontSmallCaps, &FontDescription::smallCaps, &FontDescription::setSmallCaps, FontSmallCapsOff>::createHandler());
    18601839    setPropertyHandler(CSSPropertyFontWeight, ApplyPropertyFontWeight::createHandler());
    1861     setPropertyHandler(CSSPropertyHeight, ApplyPropertyLength<&RenderStyle::height, &RenderStyle::setHeight, &RenderStyle::initialSize, AutoEnabled, IntrinsicEnabled, MinIntrinsicEnabled, NoneDisabled, UndefinedDisabled, FlexHeight>::createHandler());
     1840    setPropertyHandler(CSSPropertyHeight, ApplyPropertyLength<&RenderStyle::height, &RenderStyle::setHeight, &RenderStyle::initialSize, AutoEnabled, IntrinsicEnabled, MinIntrinsicEnabled, NoneDisabled, UndefinedDisabled>::createHandler());
    18621841    setPropertyHandler(CSSPropertyImageRendering, ApplyPropertyDefault<EImageRendering, &RenderStyle::imageRendering, EImageRendering, &RenderStyle::setImageRendering, EImageRendering, &RenderStyle::initialImageRendering>::createHandler());
    18631842    setPropertyHandler(CSSPropertyLeft, ApplyPropertyLength<&RenderStyle::left, &RenderStyle::setLeft, &RenderStyle::initialOffset, AutoEnabled>::createHandler());
     
    20382017    setPropertyHandler(CSSPropertyWhiteSpace, ApplyPropertyDefault<EWhiteSpace, &RenderStyle::whiteSpace, EWhiteSpace, &RenderStyle::setWhiteSpace, EWhiteSpace, &RenderStyle::initialWhiteSpace>::createHandler());
    20392018    setPropertyHandler(CSSPropertyWidows, ApplyPropertyDefault<short, &RenderStyle::widows, short, &RenderStyle::setWidows, short, &RenderStyle::initialWidows>::createHandler());
    2040     setPropertyHandler(CSSPropertyWidth, ApplyPropertyLength<&RenderStyle::width, &RenderStyle::setWidth, &RenderStyle::initialSize, AutoEnabled, IntrinsicEnabled, MinIntrinsicEnabled, NoneDisabled, UndefinedDisabled, FlexWidth>::createHandler());
     2019    setPropertyHandler(CSSPropertyWidth, ApplyPropertyLength<&RenderStyle::width, &RenderStyle::setWidth, &RenderStyle::initialSize, AutoEnabled, IntrinsicEnabled, MinIntrinsicEnabled, NoneDisabled, UndefinedDisabled>::createHandler());
    20412020    setPropertyHandler(CSSPropertyWordBreak, ApplyPropertyDefault<EWordBreak, &RenderStyle::wordBreak, EWordBreak, &RenderStyle::setWordBreak, EWordBreak, &RenderStyle::initialWordBreak>::createHandler());
    20422021    setPropertyHandler(CSSPropertyWordSpacing, ApplyPropertyComputeLength<int, &RenderStyle::wordSpacing, &RenderStyle::setWordSpacing, &RenderStyle::initialLetterWordSpacing, NormalEnabled, ThicknessDisabled, SVGZoomEnabled>::createHandler());
  • trunk/Source/WebCore/css/CSSValue.cpp

    r111637 r113208  
    3434#include "CSSCrossfadeValue.h"
    3535#include "CSSCursorImageValue.h"
    36 #include "CSSFlexValue.h"
    3736#include "CSSFontFaceSrcValue.h"
    3837#include "CSSFunctionValue.h"
     
    147146    case LineBoxContainClass:
    148147        return static_cast<const CSSLineBoxContainValue*>(this)->customCssText();
    149     case FlexClass:
    150         return static_cast<const CSSFlexValue*>(this)->customCssText();
    151148    case CalculationClass:
    152149        return static_cast<const CSSCalcValue*>(this)->customCssText();
     
    249246        delete static_cast<CSSLineBoxContainValue*>(this);
    250247        return;
    251     case FlexClass:
    252         delete static_cast<CSSFlexValue*>(this);
    253         return;
    254248    case CalculationClass:
    255249        delete static_cast<CSSCalcValue*>(this);
  • trunk/Source/WebCore/css/CSSValue.h

    r112730 r113208  
    8080    bool isWebKitCSSTransformValue() const { return m_classType == WebKitCSSTransformClass; }
    8181    bool isCSSLineBoxContainValue() const { return m_classType == LineBoxContainClass; }
    82     bool isFlexValue() const { return m_classType == FlexClass; }
    8382    bool isCalculationValue() const {return m_classType == CalculationClass; }
    8483#if ENABLE(CSS_FILTERS)
     
    131130        UnicodeRangeClass,
    132131        LineBoxContainClass,
    133         FlexClass,
    134132        CalculationClass,
    135133#if ENABLE(CSS_FILTERS) && ENABLE(CSS_SHADERS)
  • trunk/Source/WebCore/rendering/style/RenderStyle.h

    r112968 r113208  
    808808    EBoxPack boxPack() const { return static_cast<EBoxPack>(rareNonInheritedData->m_deprecatedFlexibleBox->pack); }
    809809
    810     float flexboxWidthPositiveFlex() const { return rareNonInheritedData->m_flexibleBox->m_widthPositiveFlex; }
    811     float flexboxWidthNegativeFlex() const { return rareNonInheritedData->m_flexibleBox->m_widthNegativeFlex; }
    812     float flexboxHeightPositiveFlex() const { return rareNonInheritedData->m_flexibleBox->m_heightPositiveFlex; }
    813     float flexboxHeightNegativeFlex() const { return rareNonInheritedData->m_flexibleBox->m_heightNegativeFlex; }
    814810    float positiveFlex() const { return rareNonInheritedData->m_flexibleBox->m_positiveFlex; }
    815811    float negativeFlex() const { return rareNonInheritedData->m_flexibleBox->m_negativeFlex; }
     
    12511247    void setBoxReflect(PassRefPtr<StyleReflection> reflect) { if (rareNonInheritedData->m_boxReflect != reflect) rareNonInheritedData.access()->m_boxReflect = reflect; }
    12521248    void setBoxSizing(EBoxSizing s) { SET_VAR(m_box, m_boxSizing, s); }
    1253     void setFlexboxWidthPositiveFlex(float f) { SET_VAR(rareNonInheritedData.access()->m_flexibleBox, m_widthPositiveFlex, f); }
    1254     void setFlexboxWidthNegativeFlex(float f) { SET_VAR(rareNonInheritedData.access()->m_flexibleBox, m_widthNegativeFlex, f); }
    1255     void setFlexboxHeightPositiveFlex(float f) { SET_VAR(rareNonInheritedData.access()->m_flexibleBox, m_heightPositiveFlex, f); }
    1256     void setFlexboxHeightNegativeFlex(float f) { SET_VAR(rareNonInheritedData.access()->m_flexibleBox, m_heightNegativeFlex, f); }
    12571249    void setPositiveFlex(float f) { SET_VAR(rareNonInheritedData.access()->m_flexibleBox, m_positiveFlex, f); }
    12581250    void setNegativeFlex(float f) { SET_VAR(rareNonInheritedData.access()->m_flexibleBox, m_negativeFlex, f); }
  • trunk/Source/WebCore/rendering/style/StyleFlexibleBoxData.cpp

    r112968 r113208  
    3232
    3333StyleFlexibleBoxData::StyleFlexibleBoxData()
    34     : m_widthPositiveFlex(RenderStyle::initialPositiveFlex())
    35     , m_widthNegativeFlex(RenderStyle::initialNegativeFlex())
    36     , m_heightPositiveFlex(RenderStyle::initialPositiveFlex())
    37     , m_heightNegativeFlex(RenderStyle::initialNegativeFlex())
    38     , m_positiveFlex(RenderStyle::initialPositiveFlex())
     34    : m_positiveFlex(RenderStyle::initialPositiveFlex())
    3935    , m_negativeFlex(RenderStyle::initialNegativeFlex())
    4036    , m_preferredSize(RenderStyle::initialFlexPreferredSize())
     
    5147StyleFlexibleBoxData::StyleFlexibleBoxData(const StyleFlexibleBoxData& o)
    5248    : RefCounted<StyleFlexibleBoxData>()
    53     , m_widthPositiveFlex(o.m_widthPositiveFlex)
    54     , m_widthNegativeFlex(o.m_widthNegativeFlex)
    55     , m_heightPositiveFlex(o.m_heightPositiveFlex)
    56     , m_heightNegativeFlex(o.m_heightNegativeFlex)
    5749    , m_positiveFlex(o.m_positiveFlex)
    5850    , m_negativeFlex(o.m_negativeFlex)
     
    7062bool StyleFlexibleBoxData::operator==(const StyleFlexibleBoxData& o) const
    7163{
    72     return m_widthPositiveFlex == o.m_widthPositiveFlex && m_widthNegativeFlex == o.m_widthNegativeFlex
    73         && m_heightPositiveFlex == o.m_heightPositiveFlex && m_heightNegativeFlex == o.m_heightNegativeFlex
    74         && m_positiveFlex == o.m_positiveFlex && m_negativeFlex == o.m_negativeFlex && m_preferredSize == o.m_preferredSize
     64    return m_positiveFlex == o.m_positiveFlex && m_negativeFlex == o.m_negativeFlex && m_preferredSize == o.m_preferredSize
    7565        && m_flexOrder == o.m_flexOrder && m_flexPack == o.m_flexPack && m_flexAlign == o.m_flexAlign
    7666        && m_flexItemAlign == o.m_flexItemAlign && m_flexDirection == o.m_flexDirection && m_flexWrap == o.m_flexWrap
  • trunk/Source/WebCore/rendering/style/StyleFlexibleBoxData.h

    r112968 r113208  
    4545    }
    4646
    47     // FIXME: Remove these once we finish implementing the -webkit-flex property.
    48     float m_widthPositiveFlex;
    49     float m_widthNegativeFlex;
    50     float m_heightPositiveFlex;
    51     float m_heightNegativeFlex;
    52 
    5347    float m_positiveFlex;
    5448    float m_negativeFlex;
Note: See TracChangeset for help on using the changeset viewer.