Index: Source/core/css/resolver/StyleBuilderCustom.cpp |
diff --git a/Source/core/css/resolver/StyleBuilderCustom.cpp b/Source/core/css/resolver/StyleBuilderCustom.cpp |
index a1de9287ea802c49371993a4c66182bbba3f6d18..3b00e9fd76819c9e34dca51c8829c231d7da35a8 100644 |
--- a/Source/core/css/resolver/StyleBuilderCustom.cpp |
+++ b/Source/core/css/resolver/StyleBuilderCustom.cpp |
@@ -47,6 +47,7 @@ |
#include "core/css/CSSAspectRatioValue.h" |
#include "core/css/CSSCursorImageValue.h" |
#include "core/css/CSSGradientValue.h" |
+#include "core/css/CSSGridTemplateValue.h" |
#include "core/css/CSSImageSetValue.h" |
#include "core/css/CSSLineBoxContainValue.h" |
#include "core/css/CSSPrimitiveValueMappings.h" |
@@ -1588,6 +1589,32 @@ void StyleBuilder::oldApplyProperty(CSSPropertyID id, StyleResolver* styleResolv |
return; |
} |
+ case CSSPropertyGridTemplate: { |
+ if (isInherit) { |
+ state.style()->setNamedGridArea(state.parentStyle()->namedGridArea()); |
+ state.style()->setNamedGridAreaRowCount(state.parentStyle()->namedGridAreaRowCount()); |
+ state.style()->setNamedGridAreaColumnCount(state.parentStyle()->namedGridAreaColumnCount()); |
+ return; |
+ } |
+ if (isInitial) { |
+ state.style()->setNamedGridArea(RenderStyle::initialNamedGridArea()); |
+ state.style()->setNamedGridAreaRowCount(RenderStyle::initialNamedGridAreaCount()); |
+ state.style()->setNamedGridAreaColumnCount(RenderStyle::initialNamedGridAreaCount()); |
+ return; |
+ } |
+ |
+ if (value->isPrimitiveValue()) { |
+ ASSERT(toCSSPrimitiveValue(value)->getValueID() == CSSValueNone); |
+ return; |
+ } |
+ |
+ CSSGridTemplateValue* gridTemplateValue = toCSSGridTemplateValue(value); |
+ state.style()->setNamedGridArea(gridTemplateValue->gridAreaMap()); |
+ state.style()->setNamedGridAreaRowCount(gridTemplateValue->rowCount()); |
+ state.style()->setNamedGridAreaColumnCount(gridTemplateValue->columnCount()); |
+ return; |
+ } |
+ |
// These properties are aliased and we already applied the property on the prefixed version. |
case CSSPropertyTransitionDelay: |
case CSSPropertyTransitionDuration: |