Index: Source/core/css/parser/CSSParserImpl.cpp |
diff --git a/Source/core/css/parser/CSSParserImpl.cpp b/Source/core/css/parser/CSSParserImpl.cpp |
index 69977dcd316555a0c13d2afcebf9ec548d8d5a18..e27c341c4260b478dfabbd7880ed93a484c7c374 100644 |
--- a/Source/core/css/parser/CSSParserImpl.cpp |
+++ b/Source/core/css/parser/CSSParserImpl.cpp |
@@ -661,7 +661,6 @@ void CSSParserImpl::consumeDeclaration(CSSParserTokenRange range, StyleRule::Typ |
if (range.consume().type() != ColonToken) |
return; // Parse error |
- // FIXME: We shouldn't allow !important in @keyframes or @font-face |
bool important = false; |
const CSSParserToken* declarationValueEnd = range.end(); |
const CSSParserToken* last = range.end() - 1; |
@@ -677,6 +676,9 @@ void CSSParserImpl::consumeDeclaration(CSSParserTokenRange range, StyleRule::Typ |
} |
} |
+ if (important && (ruleType == StyleRule::FontFace || ruleType == StyleRule::Keyframes)) |
+ return; |
+ |
if (m_observerWrapper && ruleType == StyleRule::Style) { |
size_t propertiesCount = m_parsedProperties.size(); |
if (unresolvedProperty != CSSPropertyInvalid) |