Skip to content
  • abarth@webkit.org's avatar
    Legacy CSS vendor prefixes should only work for Dashboard · 72f1b413
    abarth@webkit.org authored
    https://bugs.webkit.org/show_bug.cgi?id=111890
    
    Reviewed by Eric Seidel.
    
    Source/WebCore:
    
    Our experience with the Chromium port is that these legacy CSS vendor
    prefixes (-apple- and -khtml-) are not needed for web compatibility.
    There is reason to believe, however, that they are needed for
    compatibility with Mac OS X Dashboard widgets.
    
    This patch makes the code for these legacy CSS vendor prefixes
    enabled at runtime and only enables them when running in Dashboard
    compatibility mode. This is the first step towards the plan outlined in
    https://lists.webkit.org/pipermail/webkit-dev/2013-March/024085.html.
    
    This patch also removes support for ENABLE(LEGACY_CSS_VENDOR_PREFIXES)
    from the V8 bindings because V8 is never used with Dashboard.
    
    * bindings/generic/RuntimeEnabledFeatures.cpp:
    (WebCore):
    * bindings/generic/RuntimeEnabledFeatures.h:
    (RuntimeEnabledFeatures):
    (WebCore::RuntimeEnabledFeatures::setLegacyCSSVendorPrefixesEnabled):
    (WebCore::RuntimeEnabledFeatures::legacyCSSVendorPrefixesEnabled):
    * bindings/js/JSCSSStyleDeclarationCustom.cpp:
    (WebCore::getCSSPropertyNamePrefix):
    (WebCore::cssPropertyIDForJSCSSPropertyName):
    * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp:
    (WebCore::cssPropertyInfo):
    * css/CSSParser.cpp:
    (WebCore::CSSParser::rewriteSpecifiers):
    
    Source/WebKit/mac:
    
    Enable legacy CSS vendor prefixes when we've been asked to turn on
    Dashboard compatibility mode.
    
    * WebView/WebView.mm:
    (-[WebView _setDashboardBehavior:to:]):
    
    LayoutTests:
    
    * inspector/styles/vendor-prefixes-expected.txt:
        - Update results to show our new behavior now that -apple- and
          -khtml- are not supported.
    * platform/mac/TestExpectations:
        - Skip a test that is testing that we support -apple- prefixes.
    * platform/mac/fast/css/dashboard-region-parser.html:
        - Update test to use -webkit- rather than -apple-.
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@146025 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    72f1b413