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

Unified Diff: third_party/WebKit/Source/core/css/RuleSet.cpp

Issue 2420413005: Collect @viewport before constructing RuleSets. (Closed)
Patch Set: Rebased Created 4 years, 2 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/core/css/RuleSet.cpp
diff --git a/third_party/WebKit/Source/core/css/RuleSet.cpp b/third_party/WebKit/Source/core/css/RuleSet.cpp
index 29798f14b60b42425be81ef1ba3c40b9c8605d63..4741fae560d76f69bc82da435000b9f93fa3a7e7 100644
--- a/third_party/WebKit/Source/core/css/RuleSet.cpp
+++ b/third_party/WebKit/Source/core/css/RuleSet.cpp
@@ -257,11 +257,6 @@ void RuleSet::addPageRule(StyleRulePage* rule) {
m_pageRules.append(rule);
}
-void RuleSet::addViewportRule(StyleRuleViewport* rule) {
- ensurePendingRules(); // So that m_viewportRules.shrinkToFit() gets called.
- m_viewportRules.append(rule);
-}
-
void RuleSet::addFontFaceRule(StyleRuleFontFace* rule) {
ensurePendingRules(); // So that m_fontFaceRules.shrinkToFit() gets called.
m_fontFaceRules.append(rule);
@@ -311,8 +306,6 @@ void RuleSet::addChildRules(const HeapVector<Member<StyleRuleBase>>& rules,
addFontFaceRule(toStyleRuleFontFace(rule));
} else if (rule->isKeyframesRule()) {
addKeyframesRule(toStyleRuleKeyframes(rule));
- } else if (rule->isViewportRule()) {
- addViewportRule(toStyleRuleViewport(rule));
} else if (rule->isSupportsRule() &&
toStyleRuleSupports(rule)->conditionIsSupported()) {
addChildRules(toStyleRuleSupports(rule)->childRules(), medium,
@@ -381,7 +374,6 @@ void RuleSet::compactRules() {
m_universalRules.shrinkToFit();
m_shadowHostRules.shrinkToFit();
m_pageRules.shrinkToFit();
- m_viewportRules.shrinkToFit();
m_fontFaceRules.shrinkToFit();
m_keyframesRules.shrinkToFit();
m_deepCombinatorOrShadowPseudoRules.shrinkToFit();
@@ -416,7 +408,6 @@ DEFINE_TRACE(RuleSet) {
visitor->trace(m_shadowHostRules);
visitor->trace(m_features);
visitor->trace(m_pageRules);
- visitor->trace(m_viewportRules);
visitor->trace(m_fontFaceRules);
visitor->trace(m_keyframesRules);
visitor->trace(m_deepCombinatorOrShadowPseudoRules);
« no previous file with comments | « third_party/WebKit/Source/core/css/RuleSet.h ('k') | third_party/WebKit/Source/core/css/resolver/ScopedStyleResolver.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698