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

Side by Side Diff: sky/engine/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl

Issue 1068073002: drop 'orphan' property (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: fix ojan's comments Created 5 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 unified diff | Download patch
« no previous file with comments | « no previous file | sky/engine/core/animation/css/CSSAnimatableValueFactory.cpp » ('j') | 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 {# 2 {#
3 This file is for property handlers which use the templating engine to 3 This file is for property handlers which use the templating engine to
4 reduce (handwritten) code duplication. 4 reduce (handwritten) code duplication.
5 5
6 The `properties' dict can be used to access a property's parameters in 6 The `properties' dict can be used to access a property's parameters in
7 jinja2 templates (i.e. setter, getter, initial, type_name) 7 jinja2 templates (i.e. setter, getter, initial, type_name)
8 #} 8 #}
9 #include "config.h" 9 #include "config.h"
10 #include "StyleBuilderFunctions.h" 10 #include "StyleBuilderFunctions.h"
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 return; 136 return;
137 137
138 CSSPrimitiveValue* primitiveValue = toCSSPrimitiveValue(value); 138 CSSPrimitiveValue* primitiveValue = toCSSPrimitiveValue(value);
139 if (primitiveValue->getValueID() == {{auto_identity}}) 139 if (primitiveValue->getValueID() == {{auto_identity}})
140 state.style()->{{auto_setter}}(); 140 state.style()->{{auto_setter}}();
141 else 141 else
142 {{convert_and_set_value(property)}} 142 {{convert_and_set_value(property)}}
143 } 143 }
144 {% endmacro %} 144 {% endmacro %}
145 {{apply_auto('CSSPropertyClip')}} 145 {{apply_auto('CSSPropertyClip')}}
146 {{apply_auto('CSSPropertyOrphans')}}
147 {{apply_auto('CSSPropertyWidows')}} 146 {{apply_auto('CSSPropertyWidows')}}
148 {{apply_auto('CSSPropertyZIndex')}} 147 {{apply_auto('CSSPropertyZIndex')}}
149 148
150 static bool lengthTypeAndValueMatch(const Length& length, LengthType type, float value) 149 static bool lengthTypeAndValueMatch(const Length& length, LengthType type, float value)
151 { 150 {
152 return length.type() == type && length.value() == value; 151 return length.type() == type && length.value() == value;
153 } 152 }
154 153
155 static bool lengthTypeAndValueMatch(const LengthBox& lengthBox, LengthType type, float value) 154 static bool lengthTypeAndValueMatch(const LengthBox& lengthBox, LengthType type, float value)
156 { 155 {
(...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after
442 state.style()->set{{alignment_type}}OverflowAlignment(*pairValue->second ()); 441 state.style()->set{{alignment_type}}OverflowAlignment(*pairValue->second ());
443 } else { 442 } else {
444 state.style()->set{{alignment_type}}(*primitiveValue); 443 state.style()->set{{alignment_type}}(*primitiveValue);
445 } 444 }
446 } 445 }
447 {% endmacro %} 446 {% endmacro %}
448 {{apply_alignment('CSSPropertyAlignItems', 'AlignItems')}} 447 {{apply_alignment('CSSPropertyAlignItems', 'AlignItems')}}
449 {{apply_alignment('CSSPropertyAlignSelf', 'AlignSelf')}} 448 {{apply_alignment('CSSPropertyAlignSelf', 'AlignSelf')}}
450 449
451 } // namespace blink 450 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | sky/engine/core/animation/css/CSSAnimatableValueFactory.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698