Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(345)

Unified Diff: Source/build/scripts/css_properties.py

Issue 468543002: Revert refactoring of CSSProperty .in files (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/build/scripts/make_css_property_metadata.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/build/scripts/css_properties.py
diff --git a/Source/build/scripts/css_properties.py b/Source/build/scripts/css_properties.py
index cc4d9877975d769415be2d17ef0380bce203db49..83f2196354da92aabd215692ec1fcef6216ec9e5 100755
--- a/Source/build/scripts/css_properties.py
+++ b/Source/build/scripts/css_properties.py
@@ -9,10 +9,7 @@ from name_utilities import lower_first
class CSSProperties(in_generator.Writer):
defaults = {
- 'alias_for': None,
'longhands': '',
- 'animatable': False,
- 'inherited': False,
'font': False,
'svg': False,
'name_for_methods': None,
@@ -31,8 +28,6 @@ class CSSProperties(in_generator.Writer):
}
valid_values = {
- 'animatable': (True, False),
- 'inherited': (True, False),
'font': (True, False),
'svg': (True, False),
'custom_all': (True, False),
@@ -48,18 +43,10 @@ class CSSProperties(in_generator.Writer):
properties = self.in_file.name_dictionaries
- self._aliases = {property['name']: property['alias_for'] for property in properties if property['alias_for']}
- properties = [property for property in properties if not property['alias_for']]
-
- assert len(properties) <= 1024, 'There are more than 1024 CSS Properties, you need to update CSSProperty.h/StylePropertyMetadata m_propertyID accordingly.'
- # We currently assign 0 to CSSPropertyInvalid
- self._first_enum_value = 1
- for offset, property in enumerate(properties):
+ for property in properties:
property['property_id'] = css_name_to_enum(property['name'])
property['upper_camel_name'] = camelcase_css_name(property['name'])
property['lower_camel_name'] = lower_first(property['upper_camel_name'])
- property['enum_value'] = self._first_enum_value + offset
- property['is_internal'] = property['name'].startswith('-internal-')
self._properties_list = properties
self._properties = {property['property_id']: property for property in properties}
« no previous file with comments | « no previous file | Source/build/scripts/make_css_property_metadata.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698