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

Side by Side Diff: third_party/WebKit/Source/build/scripts/templates/ComputedStyleBase.h.tmpl

Issue 2563853002: Renamed 'type' to 'storage_type' in make_computed_style_base.py (Closed)
Patch Set: Rename Created 4 years 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 unified diff | Download patch
« no previous file with comments | « third_party/WebKit/Source/build/scripts/make_computed_style_base.py ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 {% from 'macros.tmpl' import license %} 1 {% from 'macros.tmpl' import license %}
2 {{license()}} 2 {{license()}}
3 3
4 #ifndef ComputedStyleBase_h 4 #ifndef ComputedStyleBase_h
5 #define ComputedStyleBase_h 5 #define ComputedStyleBase_h
6 6
7 #include "core/ComputedStyleBaseConstants.h" 7 #include "core/ComputedStyleBaseConstants.h"
8 #include "core/CoreExport.h" 8 #include "core/CoreExport.h"
9 9
10 {# Returns the default value for the field, converted to fit in the storage cont ainer. #} 10 {# Returns the default value for the field, converted to fit in the storage cont ainer. #}
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
93 // Copies the values of any independent inherited properties from the parent 93 // Copies the values of any independent inherited properties from the parent
94 // style that are marked as inherited by this style. 94 // style that are marked as inherited by this style.
95 void propagateIndependentInheritedProperties( 95 void propagateIndependentInheritedProperties(
96 const ComputedStyleBase& parentStyle); 96 const ComputedStyleBase& parentStyle);
97 97
98 // Fields. 98 // Fields.
99 // TODO(sashab): Remove initialFoo() static methods and update callers to 99 // TODO(sashab): Remove initialFoo() static methods and update callers to
100 // use resetFoo(), which can be more efficient. 100 // use resetFoo(), which can be more efficient.
101 {% for field in fields %} 101 {% for field in fields %}
102 // {{field.property_name}} 102 // {{field.property_name}}
103 inline static {{field.type}} {{field.initial_method_name}}() { return {{field. default_value}}; } 103 inline static {{field.storage_type}} {{field.initial_method_name}}() { return {{field.default_value}}; }
104 {{field.type}} {{field.getter_method_name}}() const { return static_cast<{{fie ld.type}}>({{field.name}}); } 104 {{field.storage_type}} {{field.getter_method_name}}() const { return static_ca st<{{field.storage_type}}>({{field.name}}); }
105 void {{field.setter_method_name}}({{field.type}} v) { {{field.name}} = static_ cast<unsigned>(v); } 105 void {{field.setter_method_name}}({{field.storage_type}} v) { {{field.name}} = static_cast<unsigned>(v); }
106 inline void {{field.resetter_method_name}}() { {{field.name}} = {{default_valu e(field)}}; } 106 inline void {{field.resetter_method_name}}() { {{field.name}} = {{default_valu e(field)}}; }
107 107
108 {% endfor %} 108 {% endfor %}
109 protected: 109 protected:
110 // Storage. 110 // Storage.
111 {% for field in fields %} 111 {% for field in fields %}
112 unsigned {{field.name}} : {{field.size}}; // {{field.type}} 112 unsigned {{field.name}} : {{field.size}}; // {{field.storage_type}}
113 {% endfor %} 113 {% endfor %}
114 }; 114 };
115 115
116 } // namespace blink 116 } // namespace blink
117 117
118 #endif // ComputedStyleBase_h 118 #endif // ComputedStyleBase_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/build/scripts/make_computed_style_base.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698