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

Unified Diff: third_party/WebKit/Source/build/scripts/templates/ComputedStyleBase.cpp.tmpl

Issue 2187493004: Add a generated ComputedStyleBase class that ComputedStyle extends (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@_make_visibility_enum_class_rebase
Patch Set: Re-ordered inheritance to match initializers Created 4 years, 3 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: third_party/WebKit/Source/build/scripts/templates/ComputedStyleBase.cpp.tmpl
diff --git a/third_party/WebKit/Source/build/scripts/templates/ComputedStyleBase.cpp.tmpl b/third_party/WebKit/Source/build/scripts/templates/ComputedStyleBase.cpp.tmpl
new file mode 100644
index 0000000000000000000000000000000000000000..d73b9934519171e844f58849cb63c79acbd2bbd1
--- /dev/null
+++ b/third_party/WebKit/Source/build/scripts/templates/ComputedStyleBase.cpp.tmpl
@@ -0,0 +1,15 @@
+{% from 'macros.tmpl' import license %}
+{{license()}}
+
+#include "core/ComputedStyleBase.h"
+
+namespace blink {
+
+void ComputedStyleBase::inheritFrom(const ComputedStyleBase& inheritParent, IsAtShadowBoundary isAtShadowBoundary)
+{
+ {% for field in fields if field.property['inherited'] %}
+ {{field.name}} = inheritParent.{{field.name}};
+ {% endfor %}
+}
+
+} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698