Ignore:
Timestamp:
Oct 16, 2020, 11:29:40 AM (5 years ago)
Author:
[email protected]
Message:

ENABLE_LEGACY_CSS_VENDOR_PREFIXES and RuntimeEnabledFeatures::legacyCSSVendorPrefixesEnabled() don't do anything
https://bugs.webkit.org/show_bug.cgi?id=217833

Reviewed by Simon Fraser.

Source/WebCore:

Remove support for ENABLE_LEGACY_CSS_VENDOR_PREFIXES, which only guarded code
that also checked legacyCSSVendorPrefixesEnabled(), which was never enabled.

  • css/CSSStyleDeclaration.cpp:
  • css/parser/CSSPropertyParser.cpp:

(WebCore::cssPropertyID):

  • page/RuntimeEnabledFeatures.h:

(WebCore::RuntimeEnabledFeatures::setLegacyCSSVendorPrefixesEnabled): Deleted.
(WebCore::RuntimeEnabledFeatures::legacyCSSVendorPrefixesEnabled const): Deleted.

Source/WTF:

  • wtf/PlatformEnable.h:
  • wtf/PlatformEnableCocoa.h:

Remove support for ENABLE_LEGACY_CSS_VENDOR_PREFIXES, which only guarded code that was always disabled.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/css/CSSStyleDeclaration.cpp

    r268564 r268599  
    3232#include "Document.h"
    3333#include "HashTools.h"
    34 #include "RuntimeEnabledFeatures.h"
    3534#include "Settings.h"
    3635#include "StyledElement.h"
     
    4645
    4746enum class PropertyNamePrefix {
    48     None, Epub, CSS, Pixel, Pos, WebKit,
    49 #if ENABLE(LEGACY_CSS_VENDOR_PREFIXES)
    50     Apple, KHTML,
    51 #endif
     47    None,
     48    Epub,
     49    CSS,
     50    Pixel,
     51    Pos,
     52    WebKit
    5253};
    5354
     
    9091    UChar firstChar = toASCIILower(propertyName[0]);
    9192    switch (firstChar) {
    92 #if ENABLE(LEGACY_CSS_VENDOR_PREFIXES)
    93     case 'a':
    94         if (RuntimeEnabledFeatures::sharedFeatures().legacyCSSVendorPrefixesEnabled() && matchesCSSPropertyNamePrefix(propertyName, "apple"))
    95             return PropertyNamePrefix::Apple;
    96         break;
    97 #endif
    9893    case 'c':
    9994        if (matchesCSSPropertyNamePrefix(propertyName, "css"))
    10095            return PropertyNamePrefix::CSS;
    10196        break;
    102 #if ENABLE(LEGACY_CSS_VENDOR_PREFIXES)
    103     case 'k':
    104         if (RuntimeEnabledFeatures::sharedFeatures().legacyCSSVendorPrefixesEnabled() && matchesCSSPropertyNamePrefix(propertyName, "khtml"))
    105             return PropertyNamePrefix::KHTML;
    106         break;
    107 #endif
    10897    case 'e':
    10998        if (matchesCSSPropertyNamePrefix(propertyName, "epub"))
     
    198187        hadPixelOrPosPrefix = true;
    199188        break;
    200 #if ENABLE(LEGACY_CSS_VENDOR_PREFIXES)
    201     case PropertyNamePrefix::Apple:
    202     case PropertyNamePrefix::KHTML:
    203         ASSERT(RuntimeEnabledFeatures::sharedFeatures().legacyCSSVendorPrefixesEnabled());
    204         writeWebKitPrefix(bufferPtr);
    205         i += 5;
    206         break;
    207 #endif
    208189    case PropertyNamePrefix::Epub:
    209190        writeEpubPrefix(bufferPtr);
Note: See TracChangeset for help on using the changeset viewer.