Changeset 35272 in webkit


Ignore:
Timestamp:
Jul 21, 2008 1:15:08 PM (16 years ago)
Author:
rwlbuis@webkit.org
Message:

Reviewed by Mitz.

https://bugs.webkit.org/show_bug.cgi?id=19966
CSS variables crash when using hex notation for colors

Support hex colors as values for the css variables.

Test: fast/css/variables/color-hex-test.html

Location:
trunk
Files:
2 added
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r35266 r35272  
     12008-07-21  Rob Buis  <buis@kde.org>
     2
     3        Reviewed by Mitz.
     4
     5        Testcase for:
     6        https://bugs.webkit.org/show_bug.cgi?id=19966
     7        CSS variables crash when using hex notation for colors
     8
     9        * fast/css/variables/color-hex-test-expected.txt: Added.
     10        * fast/css/variables/color-hex-test.html: Added.
     11
    1122008-07-20  Oliver Hunt  <oliver@apple.com>
    213
  • trunk/WebCore/ChangeLog

    r35266 r35272  
     12008-07-21  Rob Buis  <buis@kde.org>
     2
     3        Reviewed by Mitz.
     4
     5        https://bugs.webkit.org/show_bug.cgi?id=19966
     6        CSS variables crash when using hex notation for colors
     7
     8        Support hex colors as values for the css variables.
     9
     10        Test: fast/css/variables/color-hex-test.html
     11
     12        * css/CSSParserValues.cpp:
     13        (WebCore::CSSParserValue::createCSSValue):
     14        * css/CSSPrimitiveValue.cpp:
     15        (WebCore::CSSPrimitiveValue::parserValue):
     16        * css/CSSVariablesRule.cpp:
     17
    1182008-07-21  Simon Hausmann  <hausmann@webkit.org>
    219
  • trunk/WebCore/css/CSSParserValues.cpp

    r34666 r35272  
    6363    } else if (unit == CSSParserValue::Function)
    6464        parsedValue = CSSFunctionValue::create(function);
    65     else if (unit == CSSPrimitiveValue::CSS_STRING || unit == CSSPrimitiveValue::CSS_URI || unit == CSSPrimitiveValue::CSS_PARSER_VARIABLE)
     65    else if (unit == CSSPrimitiveValue::CSS_STRING || unit == CSSPrimitiveValue::CSS_URI || unit == CSSPrimitiveValue::CSS_RGBCOLOR || unit == CSSPrimitiveValue::CSS_PARSER_VARIABLE)
    6666        parsedValue = CSSPrimitiveValue::create(string, (CSSPrimitiveValue::UnitTypes)unit);
    6767    else if (unit >= CSSPrimitiveValue::CSS_NUMBER && unit <= CSSPrimitiveValue::CSS_KHZ)
  • trunk/WebCore/css/CSSPrimitiveValue.cpp

    r34932 r35272  
    783783            value.unit = m_type;
    784784            break;
     785        case CSS_RGBCOLOR:
    785786        case CSS_STRING:
    786787        case CSS_URI:
     
    810811        case CSS_COUNTER:
    811812        case CSS_RECT:
    812         case CSS_RGBCOLOR:
    813813        case CSS_PAIR:
    814814#if ENABLE(DASHBOARD_SUPPORT)
  • trunk/WebCore/css/CSSVariablesRule.cpp

    r34675 r35272  
    2727#include "CSSVariablesRule.h"
    2828
    29 #include "CSSVariablesDeclaration.h"
    3029#include "MediaList.h"
    3130#include "PlatformString.h"
Note: See TracChangeset for help on using the changeset viewer.