Index: third_party/WebKit/Source/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl |
diff --git a/third_party/WebKit/Source/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl b/third_party/WebKit/Source/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl |
index 241ed5cbcfedaca0cf9d17382d629555c865440e..7a3c729f8a1df4fc92f1a2f094ac05e2e4f60c93 100644 |
--- a/third_party/WebKit/Source/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl |
+++ b/third_party/WebKit/Source/build/scripts/templates/StyleBuilderFunctions.cpp.tmpl |
@@ -43,6 +43,9 @@ state.style()->{{property.setter}} |
{{set_value(property)}}(toCSSPrimitiveValue(value).convertTo<{{property.type_name}}>()); |
{%- endif %} |
{% endmacro %} |
+{% macro set_is_inherited(property) %} |
+state.style()->{{property.isInheritedSetter}} |
+{% endmacro %} |
namespace blink { |
@@ -58,6 +61,9 @@ namespace blink { |
{% else %} |
{{set_value(property)}}(ComputedStyle::{{property.initial}}()); |
{% endif %} |
+ {% if property.independent %} |
+ {{set_is_inherited(property)}}(true); |
esprehn
2016/07/19 03:46:26
what is this code generating that you want to set
sashab
2016/07/19 06:32:38
It's setting that the property is inherited from i
|
+ {% endif %} |
} |
{% endif %} |
@@ -71,6 +77,9 @@ namespace blink { |
{% else %} |
{{set_value(property)}}(state.parentStyle()->{{property.getter}}()); |
{% endif %} |
+ {% if property.independent %} |
+ {{set_is_inherited(property)}}(false); |
+ {% endif %} |
} |
{% endif %} |
@@ -78,6 +87,9 @@ namespace blink { |
{{declare_value_function(property_id)}} |
{ |
{{convert_and_set_value(property)}} |
+ {% if property.independent %} |
+ {{set_is_inherited(property)}}(false); |
+ {% endif %} |
} |
{% endif %} |