| OLD | NEW |
| 1 {% from 'macros.tmpl' import license %} | 1 {% from 'macros.tmpl' import license %} |
| 2 {{license()}} | 2 {{license()}} |
| 3 | 3 |
| 4 #include "core/css/CSSPropertyMetadata.h" | 4 #include "core/css/CSSPropertyMetadata.h" |
| 5 | 5 |
| 6 #include "platform/RuntimeEnabledFeatures.h" | 6 #include "platform/RuntimeEnabledFeatures.h" |
| 7 #include <bitset> | 7 #include <bitset> |
| 8 | 8 |
| 9 namespace blink { | 9 namespace blink { |
| 10 {% for flag, function_name in switches %} | 10 {% for flag, function_name in switches %} |
| (...skipping 30 matching lines...) Expand all Loading... |
| 41 {% endfor %} | 41 {% endfor %} |
| 42 {% for property_id, property in properties.items() if property.is_intern
al %} | 42 {% for property_id, property in properties.items() if property.is_intern
al %} |
| 43 enabledProperties->reset({{property_id}} - {{first_enum_value}}); | 43 enabledProperties->reset({{property_id}} - {{first_enum_value}}); |
| 44 {% endfor %} | 44 {% endfor %} |
| 45 } | 45 } |
| 46 | 46 |
| 47 if (unresolvedProperty >= {{first_enum_value}}) | 47 if (unresolvedProperty >= {{first_enum_value}}) |
| 48 return enabledProperties->test(property - {{first_enum_value}}); | 48 return enabledProperties->test(property - {{first_enum_value}}); |
| 49 | 49 |
| 50 if (unresolvedProperty == CSSPropertyVariable) | 50 if (unresolvedProperty == CSSPropertyVariable) |
| 51 return RuntimeEnabledFeatures::cssVariablesEnabled(); | 51 return true; |
| 52 ASSERT(unresolvedProperty == CSSPropertyApplyAtRule); | 52 ASSERT(unresolvedProperty == CSSPropertyApplyAtRule); |
| 53 return RuntimeEnabledFeatures::cssApplyAtRulesEnabled(); | 53 return RuntimeEnabledFeatures::cssApplyAtRulesEnabled(); |
| 54 } | 54 } |
| 55 | 55 |
| 56 void CSSPropertyMetadata::filterEnabledCSSPropertiesIntoVector(const CSSProperty
ID* properties, size_t propertyCount, Vector<CSSPropertyID>& outVector) | 56 void CSSPropertyMetadata::filterEnabledCSSPropertiesIntoVector(const CSSProperty
ID* properties, size_t propertyCount, Vector<CSSPropertyID>& outVector) |
| 57 { | 57 { |
| 58 for (unsigned i = 0; i < propertyCount; i++) { | 58 for (unsigned i = 0; i < propertyCount; i++) { |
| 59 CSSPropertyID property = properties[i]; | 59 CSSPropertyID property = properties[i]; |
| 60 if (isEnabledProperty(property)) | 60 if (isEnabledProperty(property)) |
| 61 outVector.append(property); | 61 outVector.append(property); |
| 62 } | 62 } |
| 63 } | 63 } |
| 64 | 64 |
| 65 bool CSSPropertyMetadata::isDescriptorOnly(CSSPropertyID property) | 65 bool CSSPropertyMetadata::isDescriptorOnly(CSSPropertyID property) |
| 66 { | 66 { |
| 67 return property >= {{descriptors[0].property_id}} && property <= {{descripto
rs[-1].property_id}}; | 67 return property >= {{descriptors[0].property_id}} && property <= {{descripto
rs[-1].property_id}}; |
| 68 } | 68 } |
| 69 | 69 |
| 70 } // namespace blink | 70 } // namespace blink |
| OLD | NEW |