From 902f11db5a1554b7dee73dedda865686a2118e69 Mon Sep 17 00:00:00 2001 From: "commit-queue@webkit.org" Date: Mon, 4 Mar 2013 18:59:31 +0000 Subject: [PATCH] getComputedStyle not implemented for -webkit-columns shorthand https://bugs.webkit.org/show_bug.cgi?id=111236 Patch by Uday Kiran on 2013-03-04 Reviewed by Alexis Menard. Source/WebCore: Implement getComputedStyle for -webkit-columns shorthand. Test: fast/css/getComputedStyle/getComputedStyle-webkit-columns-shorthand.html * css/CSSComputedStyleDeclaration.cpp: (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): LayoutTests: Add test to check getComputedStyle for -webkit-columns. * fast/css/getComputedStyle/getComputedStyle-webkit-columns-shorthand-expected.txt: Added. * fast/css/getComputedStyle/getComputedStyle-webkit-columns-shorthand.html: Added. git-svn-id: https://svn.webkit.org/repository/webkit/trunk@144647 268f45cc-cd09-0410-ab3c-d52691b4dbfc --- LayoutTests/ChangeLog | 12 ++++ ...utedStyle-webkit-columns-shorthand-expected.txt | 45 +++++++++++++ .../getComputedStyle-webkit-columns-shorthand.html | 74 ++++++++++++++++++++++ Source/WebCore/ChangeLog | 14 ++++ Source/WebCore/css/CSSComputedStyleDeclaration.cpp | 3 +- 5 files changed, 147 insertions(+), 1 deletion(-) create mode 100644 LayoutTests/fast/css/getComputedStyle/getComputedStyle-webkit-columns-shorthand-expected.txt create mode 100644 LayoutTests/fast/css/getComputedStyle/getComputedStyle-webkit-columns-shorthand.html diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog index c03058c..92cd74e 100644 --- a/LayoutTests/ChangeLog +++ b/LayoutTests/ChangeLog @@ -1,3 +1,15 @@ +2013-03-04 Uday Kiran + + getComputedStyle not implemented for -webkit-columns shorthand + https://bugs.webkit.org/show_bug.cgi?id=111236 + + Reviewed by Alexis Menard. + + Add test to check getComputedStyle for -webkit-columns. + + * fast/css/getComputedStyle/getComputedStyle-webkit-columns-shorthand-expected.txt: Added. + * fast/css/getComputedStyle/getComputedStyle-webkit-columns-shorthand.html: Added. + 2013-03-04 Alexis Menard transition-property property and transition shorthand property doesn't accept "all, all". diff --git a/LayoutTests/fast/css/getComputedStyle/getComputedStyle-webkit-columns-shorthand-expected.txt b/LayoutTests/fast/css/getComputedStyle/getComputedStyle-webkit-columns-shorthand-expected.txt new file mode 100644 index 0000000..c2033c8 --- /dev/null +++ b/LayoutTests/fast/css/getComputedStyle/getComputedStyle-webkit-columns-shorthand-expected.txt @@ -0,0 +1,45 @@ +Test to make sure -webkit-columns property returns CSSValueList properly. + +On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". + + +PASS computedStyle.getPropertyValue('-webkit-columns') is "10px 2" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').toString() is "[object CSSValueList]" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').cssText is "10px 2" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').length is 2 +PASS computedStyle.getPropertyCSSValue('-webkit-columns').item(0).getFloatValue(CSSPrimitiveValue.CSS_PX) is 10 +PASS computedStyle.getPropertyCSSValue('-webkit-columns').item(1).getFloatValue(CSSPrimitiveValue.CSS_NUMBER) is 2 +PASS computedStyle.getPropertyValue('-webkit-columns') is "10px auto" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').toString() is "[object CSSValueList]" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').cssText is "10px auto" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').length is 2 +PASS computedStyle.getPropertyCSSValue('-webkit-columns').item(0).getFloatValue(CSSPrimitiveValue.CSS_PX) is 10 +PASS computedStyle.getPropertyCSSValue('-webkit-columns').item(1).getStringValue() is "auto" +PASS computedStyle.getPropertyValue('-webkit-columns') is "auto 2" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').toString() is "[object CSSValueList]" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').cssText is "auto 2" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').length is 2 +PASS computedStyle.getPropertyCSSValue('-webkit-columns').item(0).getStringValue() is "auto" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').item(1).getFloatValue(CSSPrimitiveValue.CSS_NUMBER) is 2 +PASS computedStyle.getPropertyValue('-webkit-columns') is "auto 2" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').toString() is "[object CSSValueList]" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').cssText is "auto 2" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').length is 2 +PASS computedStyle.getPropertyCSSValue('-webkit-columns').item(0).getStringValue() is "auto" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').item(1).getFloatValue(CSSPrimitiveValue.CSS_NUMBER) is 2 +PASS computedStyle.getPropertyValue('-webkit-columns') is "auto auto" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').toString() is "[object CSSValueList]" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').cssText is "auto auto" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').length is 2 +PASS computedStyle.getPropertyCSSValue('-webkit-columns').item(0).getStringValue() is "auto" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').item(1).getStringValue() is "auto" +PASS computedStyle.getPropertyValue('-webkit-columns') is "10px auto" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').toString() is "[object CSSValueList]" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').cssText is "10px auto" +PASS computedStyle.getPropertyCSSValue('-webkit-columns').length is 2 +PASS computedStyle.getPropertyCSSValue('-webkit-columns').item(0).getFloatValue(CSSPrimitiveValue.CSS_PX) is 10 +PASS computedStyle.getPropertyCSSValue('-webkit-columns').item(1).getStringValue() is "auto" +PASS successfullyParsed is true + +TEST COMPLETE + diff --git a/LayoutTests/fast/css/getComputedStyle/getComputedStyle-webkit-columns-shorthand.html b/LayoutTests/fast/css/getComputedStyle/getComputedStyle-webkit-columns-shorthand.html new file mode 100644 index 0000000..c2e5535 --- /dev/null +++ b/LayoutTests/fast/css/getComputedStyle/getComputedStyle-webkit-columns-shorthand.html @@ -0,0 +1,74 @@ + + + + + + + + + + + diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog index 13180c3..b065e50 100644 --- a/Source/WebCore/ChangeLog +++ b/Source/WebCore/ChangeLog @@ -1,3 +1,17 @@ +2013-03-04 Uday Kiran + + getComputedStyle not implemented for -webkit-columns shorthand + https://bugs.webkit.org/show_bug.cgi?id=111236 + + Reviewed by Alexis Menard. + + Implement getComputedStyle for -webkit-columns shorthand. + + Test: fast/css/getComputedStyle/getComputedStyle-webkit-columns-shorthand.html + + * css/CSSComputedStyleDeclaration.cpp: + (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): + 2013-03-04 Levi Weintraub Add support for 8 bit TextRuns on Chromium Linux & Mac diff --git a/Source/WebCore/css/CSSComputedStyleDeclaration.cpp b/Source/WebCore/css/CSSComputedStyleDeclaration.cpp index 1a93264b..38e8f29 100644 --- a/Source/WebCore/css/CSSComputedStyleDeclaration.cpp +++ b/Source/WebCore/css/CSSComputedStyleDeclaration.cpp @@ -2682,6 +2682,8 @@ PassRefPtr CSSComputedStyleDeclaration::getPropertyCSSValue(CSSPropert return getCSSPropertyValuesForSidesShorthand(borderWidthShorthand()); case CSSPropertyWebkitColumnRule: return getCSSPropertyValuesForShorthandProperties(webkitColumnRuleShorthand()); + case CSSPropertyWebkitColumns: + return getCSSPropertyValuesForShorthandProperties(webkitColumnsShorthand()); case CSSPropertyListStyle: return getCSSPropertyValuesForShorthandProperties(listStyleShorthand()); case CSSPropertyMargin: @@ -2763,7 +2765,6 @@ PassRefPtr CSSComputedStyleDeclaration::getPropertyCSSValue(CSSPropert /* Unimplemented -webkit- properties */ case CSSPropertyWebkitAnimation: case CSSPropertyWebkitBorderRadius: - case CSSPropertyWebkitColumns: case CSSPropertyWebkitMarginCollapse: case CSSPropertyWebkitMarquee: case CSSPropertyWebkitMarqueeSpeed: -- 1.8.3.1