Changeset 100570 in webkit
- Timestamp:
- Nov 17, 2011 12:08:31 AM (12 years ago)
- Location:
- trunk
- Files:
-
- 6 added
- 20 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r100565 r100570 1 2011-11-17 Mihnea Ovidenie <mihnea@adobe.com> 2 3 CSS exclusions: parse the wrap-flow and wrap-through properties 4 https://bugs.webkit.org/show_bug.cgi?id=71904 5 6 Reviewed by Dean Jackson. 7 8 * fast/css/getComputedStyle/computed-style-expected.txt: 9 * fast/css/getComputedStyle/computed-style-without-renderer-expected.txt: 10 * fast/exclusions/script-tests/wrap-flow-parsing.js: Added. 11 * fast/exclusions/script-tests/wrap-through-parsing.js: Added. 12 * fast/exclusions/wrap-flow-parsing-expected.txt: Added. 13 * fast/exclusions/wrap-flow-parsing.html: Added. 14 * fast/exclusions/wrap-through-parsing-expected.txt: Added. 15 * fast/exclusions/wrap-through-parsing.html: Added. 16 * platform/chromium-win/fast/css/getComputedStyle/computed-style-expected.txt: 17 * platform/chromium-win/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt: 18 * platform/chromium-win/svg/css/getComputedStyle-basic-expected.txt: 19 * svg/css/getComputedStyle-basic-expected.txt: 20 1 21 2011-11-16 Dean Jackson <dino@apple.com> 2 22 -
trunk/LayoutTests/fast/css/getComputedStyle/computed-style-expected.txt
r100198 r100570 212 212 -webkit-region-break-before: auto; 213 213 -webkit-region-break-inside: auto; 214 -webkit-wrap-flow: auto; 215 -webkit-wrap-through: wrap; 214 216 clip-path: none; 215 217 clip-rule: nonzero; -
trunk/LayoutTests/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt
r100198 r100570 211 211 -webkit-region-break-before: auto 212 212 -webkit-region-break-inside: auto 213 -webkit-wrap-flow: auto 214 -webkit-wrap-through: wrap 213 215 clip-path: none 214 216 clip-rule: nonzero -
trunk/LayoutTests/platform/chromium-win/fast/css/getComputedStyle/computed-style-expected.txt
r100198 r100570 212 212 -webkit-region-break-before: auto; 213 213 -webkit-region-break-inside: auto; 214 -webkit-wrap-flow: auto; 215 -webkit-wrap-through: wrap; 214 216 clip-path: none; 215 217 clip-rule: nonzero; -
trunk/LayoutTests/platform/chromium-win/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt
r100198 r100570 211 211 -webkit-region-break-before: auto 212 212 -webkit-region-break-inside: auto 213 -webkit-wrap-flow: auto 214 -webkit-wrap-through: wrap 213 215 clip-path: none 214 216 clip-rule: nonzero -
trunk/LayoutTests/platform/chromium-win/svg/css/getComputedStyle-basic-expected.txt
r100198 r100570 421 421 rect: style.getPropertyValue(-webkit-region-break-inside) : auto 422 422 rect: style.getPropertyCSSValue(-webkit-region-break-inside) : [object CSSPrimitiveValue] 423 rect: style.getPropertyValue(-webkit-wrap-flow) : auto 424 rect: style.getPropertyCSSValue(-webkit-wrap-flow) : [object CSSPrimitiveValue] 425 rect: style.getPropertyValue(-webkit-wrap-through) : wrap 426 rect: style.getPropertyCSSValue(-webkit-wrap-through) : [object CSSPrimitiveValue] 423 427 rect: style.getPropertyValue(clip-path) : none 424 428 rect: style.getPropertyCSSValue(clip-path) : [object CSSPrimitiveValue] … … 917 921 g: style.getPropertyValue(-webkit-region-break-inside) : auto 918 922 g: style.getPropertyCSSValue(-webkit-region-break-inside) : [object CSSPrimitiveValue] 923 g: style.getPropertyValue(-webkit-wrap-flow) : auto 924 g: style.getPropertyCSSValue(-webkit-wrap-flow) : [object CSSPrimitiveValue] 925 g: style.getPropertyValue(-webkit-wrap-through) : wrap 926 g: style.getPropertyCSSValue(-webkit-wrap-through) : [object CSSPrimitiveValue] 919 927 g: style.getPropertyValue(clip-path) : none 920 928 g: style.getPropertyCSSValue(clip-path) : [object CSSPrimitiveValue] -
trunk/LayoutTests/svg/css/getComputedStyle-basic-expected.txt
r100198 r100570 421 421 rect: style.getPropertyValue(-webkit-region-break-inside) : auto 422 422 rect: style.getPropertyCSSValue(-webkit-region-break-inside) : [object CSSPrimitiveValue] 423 rect: style.getPropertyValue(-webkit-wrap-flow) : auto 424 rect: style.getPropertyCSSValue(-webkit-wrap-flow) : [object CSSPrimitiveValue] 425 rect: style.getPropertyValue(-webkit-wrap-through) : wrap 426 rect: style.getPropertyCSSValue(-webkit-wrap-through) : [object CSSPrimitiveValue] 423 427 rect: style.getPropertyValue(clip-path) : none 424 428 rect: style.getPropertyCSSValue(clip-path) : [object CSSPrimitiveValue] … … 917 921 g: style.getPropertyValue(-webkit-region-break-inside) : auto 918 922 g: style.getPropertyCSSValue(-webkit-region-break-inside) : [object CSSPrimitiveValue] 923 g: style.getPropertyValue(-webkit-wrap-flow) : auto 924 g: style.getPropertyCSSValue(-webkit-wrap-flow) : [object CSSPrimitiveValue] 925 g: style.getPropertyValue(-webkit-wrap-through) : wrap 926 g: style.getPropertyCSSValue(-webkit-wrap-through) : [object CSSPrimitiveValue] 919 927 g: style.getPropertyValue(clip-path) : none 920 928 g: style.getPropertyCSSValue(clip-path) : [object CSSPrimitiveValue] -
trunk/Source/WebCore/ChangeLog
r100565 r100570 1 2011-11-17 Mihnea Ovidenie <mihnea@adobe.com> 2 3 CSS exclusions: parse the wrap-flow and wrap-through properties 4 https://bugs.webkit.org/show_bug.cgi?id=71904 5 6 Reviewed by Dean Jackson. 7 8 Tests: fast/exclusions/wrap-flow-parsing.html 9 fast/exclusions/wrap-through-parsing.html 10 11 * css/CSSComputedStyleDeclaration.cpp: 12 (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): 13 * css/CSSParser.cpp: 14 (WebCore::CSSParser::parseValue): 15 * css/CSSPrimitiveValueMappings.h: 16 (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): 17 (WebCore::CSSPrimitiveValue::operator WrapFlow): 18 (WebCore::CSSPrimitiveValue::operator WrapThrough): 19 * css/CSSProperty.cpp: 20 (WebCore::CSSProperty::isInheritedProperty): 21 * css/CSSPropertyNames.in: 22 * css/CSSStyleSelector.cpp: 23 (WebCore::CSSStyleSelector::applyProperty): 24 * css/CSSValueKeywords.in: 25 * rendering/style/RenderStyle.cpp: 26 (WebCore::RenderStyle::diff): 27 * rendering/style/RenderStyle.h: 28 (WebCore::InheritedFlags::wrapFlow): 29 (WebCore::InheritedFlags::wrapThrough): 30 (WebCore::InheritedFlags::setWrapFlow): 31 (WebCore::InheritedFlags::setWrapThrough): 32 (WebCore::InheritedFlags::initialWrapFlow): 33 (WebCore::InheritedFlags::initialWrapThrough): 34 * rendering/style/RenderStyleConstants.h: 35 * rendering/style/StyleRareNonInheritedData.cpp: 36 (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData): 37 (WebCore::StyleRareNonInheritedData::operator==): 38 * rendering/style/StyleRareNonInheritedData.h: 39 1 40 2011-11-16 Dean Jackson <dino@apple.com> 2 41 -
trunk/Source/WebCore/css/CSSComputedStyleDeclaration.cpp
r100560 r100570 285 285 CSSPropertyWebkitRegionBreakAfter, 286 286 CSSPropertyWebkitRegionBreakBefore, 287 CSSPropertyWebkitRegionBreakInside 287 CSSPropertyWebkitRegionBreakInside, 288 CSSPropertyWebkitWrapFlow, 289 CSSPropertyWebkitWrapThrough 288 290 #if ENABLE(SVG) 289 291 , … … 2154 2156 return primitiveValueCache->createValue(style->wrapShape()); 2155 2157 2158 case CSSPropertyWebkitWrapFlow: 2159 return primitiveValueCache->createValue(style->wrapFlow()); 2160 case CSSPropertyWebkitWrapThrough: 2161 return primitiveValueCache->createValue(style->wrapThrough()); 2156 2162 #if ENABLE(SVG) 2157 2163 case CSSPropertyClipPath: -
trunk/Source/WebCore/css/CSSParser.cpp
r100565 r100570 2199 2199 else if (value->unit == CSSParserValue::Function) 2200 2200 return parseWrapShape(important); 2201 break; 2202 2203 case CSSPropertyWebkitWrapFlow: 2204 if (id == CSSValueAuto || id == CSSValueBoth || id == CSSValueLeft || id == CSSValueRight || id == CSSValueMaximum || id == CSSValueClear) 2205 validPrimitive = true; 2206 break; 2207 2208 case CSSPropertyWebkitWrapThrough: 2209 if (id == CSSValueWrap || id == CSSValueNone) 2210 validPrimitive = true; 2201 2211 break; 2202 2212 -
trunk/Source/WebCore/css/CSSPrimitiveValueMappings.h
r100389 r100570 3453 3453 } 3454 3454 3455 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(WrapFlow wrapFlow) 3456 : CSSValue(PrimitiveClass) 3457 { 3458 m_primitiveUnitType = CSS_IDENT; 3459 switch (wrapFlow) { 3460 case WrapFlowAuto: 3461 m_value.ident = CSSValueAuto; 3462 break; 3463 case WrapFlowBoth: 3464 m_value.ident = CSSValueBoth; 3465 break; 3466 case WrapFlowLeft: 3467 m_value.ident = CSSValueLeft; 3468 break; 3469 case WrapFlowRight: 3470 m_value.ident = CSSValueRight; 3471 break; 3472 case WrapFlowMaximum: 3473 m_value.ident = CSSValueMaximum; 3474 break; 3475 case WrapFlowClear: 3476 m_value.ident = CSSValueClear; 3477 break; 3478 } 3479 } 3480 3481 template<> inline CSSPrimitiveValue::operator WrapFlow() const 3482 { 3483 switch (m_value.ident) { 3484 case CSSValueAuto: 3485 return WrapFlowAuto; 3486 case CSSValueBoth: 3487 return WrapFlowBoth; 3488 case CSSValueLeft: 3489 return WrapFlowLeft; 3490 case CSSValueRight: 3491 return WrapFlowRight; 3492 case CSSValueMaximum: 3493 return WrapFlowMaximum; 3494 case CSSValueClear: 3495 return WrapFlowClear; 3496 default: 3497 ASSERT_NOT_REACHED(); 3498 return WrapFlowAuto; 3499 } 3500 } 3501 3502 template<> inline CSSPrimitiveValue::CSSPrimitiveValue(WrapThrough wrapThrough) 3503 : CSSValue(PrimitiveClass) 3504 { 3505 m_primitiveUnitType = CSS_IDENT; 3506 switch (wrapThrough) { 3507 case WrapThroughWrap: 3508 m_value.ident = CSSValueWrap; 3509 break; 3510 case WrapThroughNone: 3511 m_value.ident = CSSValueNone; 3512 break; 3513 } 3514 } 3515 3516 template<> inline CSSPrimitiveValue::operator WrapThrough() const 3517 { 3518 switch (m_value.ident) { 3519 case CSSValueWrap: 3520 return WrapThroughWrap; 3521 case CSSValueNone: 3522 return WrapThroughNone; 3523 default: 3524 ASSERT_NOT_REACHED(); 3525 return WrapThroughWrap; 3526 } 3527 } 3528 3455 3529 #if ENABLE(SVG) 3456 3530 -
trunk/Source/WebCore/css/CSSProperty.cpp
r100198 r100570 636 636 case CSSPropertyWebkitRegionBreakBefore: 637 637 case CSSPropertyWebkitRegionBreakInside: 638 case CSSPropertyWebkitWrapFlow: 639 case CSSPropertyWebkitWrapThrough: 638 640 #if ENABLE(SVG) 639 641 case CSSPropertyClipPath: -
trunk/Source/WebCore/css/CSSPropertyNames.in
r100198 r100570 359 359 -webkit-region-break-before 360 360 -webkit-region-break-inside 361 -webkit-wrap-flow 362 -webkit-wrap-through 361 363 #if defined(ENABLE_TOUCH_EVENTS) && ENABLE_TOUCH_EVENTS 362 364 -webkit-tap-highlight-color -
trunk/Source/WebCore/css/CSSStyleSelector.cpp
r100560 r100570 3870 3870 m_style->setWrapShape(primitiveValue->getShapeValue()); 3871 3871 3872 return; 3873 3874 case CSSPropertyWebkitWrapFlow: 3875 HANDLE_INHERIT_AND_INITIAL_AND_PRIMITIVE(wrapFlow, WrapFlow); 3876 return; 3877 3878 case CSSPropertyWebkitWrapThrough: 3879 HANDLE_INHERIT_AND_INITIAL_AND_PRIMITIVE(wrapThrough, WrapThrough); 3872 3880 return; 3873 3881 -
trunk/Source/WebCore/css/CSSValueKeywords.in
r100389 r100570 857 857 break 858 858 859 // -webkit-wrap-flow 860 // auto 861 // both 862 // left 863 // right 864 maximum 865 // clear 866 867 // -webkit-wrap-through 868 wrap 869 // none 870 859 871 #if defined(ENABLE_CSS_FILTERS) && ENABLE_CSS_FILTERS 860 872 // -webkit-filter -
trunk/Source/WebCore/rendering/style/RenderStyle.cpp
r100198 r100570 384 384 385 385 if (rareNonInheritedData->m_regionOverflow != other->rareNonInheritedData->m_regionOverflow) 386 return StyleDifferenceLayout; 387 388 if (rareNonInheritedData->m_wrapFlow != other->rareNonInheritedData->m_wrapFlow 389 || rareNonInheritedData->m_wrapThrough != other->rareNonInheritedData->m_wrapThrough) 386 390 return StyleDifferenceLayout; 387 391 -
trunk/Source/WebCore/rendering/style/RenderStyle.h
r100416 r100570 808 808 const AtomicString& lineGrid() const { return rareInheritedData->m_lineGrid; } 809 809 LineGridSnap lineGridSnap() const { return static_cast<LineGridSnap>(rareInheritedData->m_lineGridSnap); } 810 811 WrapFlow wrapFlow() const { return static_cast<WrapFlow>(rareNonInheritedData->m_wrapFlow); } 812 WrapThrough wrapThrough() const { return static_cast<WrapThrough>(rareNonInheritedData->m_wrapThrough); } 810 813 811 814 // Apple-specific property getter methods … … 1195 1198 void setRegionThread(const AtomicString& regionThread) { SET_VAR(rareNonInheritedData, m_regionThread, regionThread); } 1196 1199 void setRegionOverflow(RegionOverflow regionOverflow) { SET_VAR(rareNonInheritedData, m_regionOverflow, regionOverflow); } 1200 1201 void setWrapFlow(WrapFlow wrapFlow) { SET_VAR(rareNonInheritedData, m_wrapFlow, wrapFlow); } 1202 void setWrapThrough(WrapThrough wrapThrough) { SET_VAR(rareNonInheritedData, m_wrapThrough, wrapThrough); } 1197 1203 1198 1204 // Apple-specific property setters … … 1483 1489 static RegionOverflow initialRegionOverflow() { return AutoRegionOverflow; } 1484 1490 1491 static WrapFlow initialWrapFlow() { return WrapFlowAuto; } 1492 static WrapThrough initialWrapThrough() { return WrapThroughWrap; } 1493 1485 1494 // Keep these at the end. 1486 1495 static LineClampValue initialLineClamp() { return LineClampValue(); } -
trunk/Source/WebCore/rendering/style/RenderStyleConstants.h
r100389 r100570 461 461 enum LineGridSnap { LineGridSnapNone, LineGridSnapBaseline, LineGridSnapBounds }; 462 462 463 enum WrapFlow { WrapFlowAuto, WrapFlowBoth, WrapFlowLeft, WrapFlowRight, WrapFlowMaximum, WrapFlowClear }; 464 465 enum WrapThrough { WrapThroughWrap, WrapThroughNone }; 466 463 467 } // namespace WebCore 464 468 -
trunk/Source/WebCore/rendering/style/StyleRareNonInheritedData.cpp
r100198 r100570 63 63 , m_borderFit(RenderStyle::initialBorderFit()) 64 64 , m_textCombine(RenderStyle::initialTextCombine()) 65 , m_wrapFlow(RenderStyle::initialWrapFlow()) 66 , m_wrapThrough(RenderStyle::initialWrapThrough()) 65 67 #if USE(ACCELERATED_COMPOSITING) 66 68 , m_runningAcceleratedAnimation(false) … … 120 122 , m_borderFit(o.m_borderFit) 121 123 , m_textCombine(o.m_textCombine) 124 , m_wrapFlow(o.m_wrapFlow) 125 , m_wrapThrough(o.m_wrapThrough) 122 126 #if USE(ACCELERATED_COMPOSITING) 123 127 , m_runningAcceleratedAnimation(o.m_runningAcceleratedAnimation) … … 177 181 && (m_regionOverflow == o.m_regionOverflow) 178 182 && (m_wrapShape == o.m_wrapShape) 183 && (m_wrapFlow == o.m_wrapFlow) 184 && (m_wrapThrough == o.m_wrapThrough) 179 185 && m_visitedLinkBackgroundColor == o.m_visitedLinkBackgroundColor 180 186 && m_visitedLinkOutlineColor == o.m_visitedLinkOutlineColor -
trunk/Source/WebCore/rendering/style/StyleRareNonInheritedData.h
r100198 r100570 157 157 unsigned m_textCombine : 1; // CSS3 text-combine properties 158 158 159 unsigned m_wrapFlow: 3; // WrapFlow 160 unsigned m_wrapThrough: 1; // WrapThrough 161 159 162 #if USE(ACCELERATED_COMPOSITING) 160 163 bool m_runningAcceleratedAnimation : 1;
Note: See TracChangeset
for help on using the changeset viewer.