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

Unified Diff: third_party/WebKit/Source/build/scripts/make_css_property_apis.py

Issue 2849133002: Added property id comments to CSSDescriptorIndices entries. (Closed)
Patch Set: replaced unrelated whitespace Created 3 years, 8 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 | third_party/WebKit/Source/build/scripts/templates/CSSPropertyDescriptor.cpp.tmpl » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/build/scripts/make_css_property_apis.py
diff --git a/third_party/WebKit/Source/build/scripts/make_css_property_apis.py b/third_party/WebKit/Source/build/scripts/make_css_property_apis.py
index c092ae98a4ae8abc68dea0d67a18d645c4026777..d94aa915df8e1049ce498d89d3d51508441a04bd 100755
--- a/third_party/WebKit/Source/build/scripts/make_css_property_apis.py
+++ b/third_party/WebKit/Source/build/scripts/make_css_property_apis.py
@@ -94,11 +94,11 @@ class CSSPropertyAPIWriter(StyleBuilderWriter):
self._invalid_descriptor_index = 0
# Initialize the whole thing to the invalid descriptor to handle gaps
num_indices = self.last_unresolved_property_id + 1
- self._descriptor_indices = [self._invalid_descriptor_index] * num_indices
+ self._descriptor_indices = dict.fromkeys(xrange(num_indices), {'id': self._invalid_descriptor_index, 'api': None})
# Now populate all entries for which there exists a class, i.e. that aren't gaps
for api_class in self._api_classes:
for property_enum in property_enums_for_class[api_class.classname]:
- self._descriptor_indices[property_enum] = api_class.index
+ self._descriptor_indices[property_enum] = {'id': api_class.index, 'api': api_class.classname}
@template_expander.use_jinja('CSSPropertyDescriptor.cpp.tmpl')
def generate_property_descriptor_cpp(self):
« no previous file with comments | « no previous file | third_party/WebKit/Source/build/scripts/templates/CSSPropertyDescriptor.cpp.tmpl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698