Chromium Code Reviews| Index: third_party/WebKit/Source/core/css/CSSGlobalRuleSet.cpp |
| diff --git a/third_party/WebKit/Source/core/css/CSSGlobalRuleSet.cpp b/third_party/WebKit/Source/core/css/CSSGlobalRuleSet.cpp |
| index df122f876f9ab97781a4a6bd1b11ea2bd837fb08..97301d6521b7b1cc42b0d605eba1e191bea9b8c6 100644 |
| --- a/third_party/WebKit/Source/core/css/CSSGlobalRuleSet.cpp |
| +++ b/third_party/WebKit/Source/core/css/CSSGlobalRuleSet.cpp |
| @@ -69,6 +69,15 @@ void CSSGlobalRuleSet::update(Document& document) { |
| m_uncommonAttributeRuleSet = makeRuleSet(m_features.uncommonAttributeRules()); |
| } |
| +void CSSGlobalRuleSet::reset() { |
|
sof
2016/12/20 18:42:09
nit: is this leaving the object in a usable state?
|
| + m_features.clear(); |
| + m_siblingRuleSet = nullptr; |
| + m_uncommonAttributeRuleSet = nullptr; |
| + m_watchedSelectorsRuleSet = nullptr; |
| + m_hasFullscreenUAStyle = false; |
| + m_isDirty = true; |
| +} |
| + |
| DEFINE_TRACE(CSSGlobalRuleSet) { |
| visitor->trace(m_features); |
| visitor->trace(m_siblingRuleSet); |