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

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

Issue 1192983003: CSS Custom Properties (Variables) (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: ToTed Created 5 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
Index: Source/build/scripts/make_css_property_names.py
diff --git a/Source/build/scripts/make_css_property_names.py b/Source/build/scripts/make_css_property_names.py
index 4a591d3c7a371d8485fe9a4c411f33dab183123c..23b4c48e1233f017960690857af516cd851ee802 100755
--- a/Source/build/scripts/make_css_property_names.py
+++ b/Source/build/scripts/make_css_property_names.py
@@ -29,6 +29,7 @@ namespace blink {
enum CSSPropertyID {
CSSPropertyInvalid = 0,
%(property_enums)s
+ CSSPropertyVariable = %(properties_count)s,
};
const int firstCSSProperty = %(first_property_id)s;
@@ -192,8 +193,8 @@ class CSSPropertyNamesWriter(css_properties.CSSProperties):
'class_name': self.class_name,
'property_enums': "\n".join(map(self._enum_declaration, self._properties_including_aliases)),
'first_property_id': self._first_enum_value,
- 'properties_count': len(self._properties),
- 'last_property_id': self._first_enum_value + len(self._properties) - 1,
+ 'properties_count': len(self._properties) + 1,
alancutter (OOO until 2018) 2015/08/25 01:59:08 Add comment here stating the +1 is for CSSProperty
Timothy Loh 2015/08/25 09:21:09 Err.. this is a bit weird. numCSSProperties now ac
+ 'last_property_id': self._first_enum_value + len(self._properties),
'last_unresolved_property_id': max(property["enum_value"] for property in self._properties_including_aliases),
'max_name_length': max(map(len, self._properties)),
}

Powered by Google App Engine
This is Rietveld 408576698