| Index: third_party/WebKit/Source/core/dom/StyleEngine.cpp
|
| diff --git a/third_party/WebKit/Source/core/dom/StyleEngine.cpp b/third_party/WebKit/Source/core/dom/StyleEngine.cpp
|
| index 819ad3dbd66768c38d7a1b452ff5413fee992d11..7a7f808e83527fcc84d7c23afb6a1aa8f76c933b 100644
|
| --- a/third_party/WebKit/Source/core/dom/StyleEngine.cpp
|
| +++ b/third_party/WebKit/Source/core/dom/StyleEngine.cpp
|
| @@ -163,7 +163,7 @@ void StyleEngine::addPendingSheet()
|
| void StyleEngine::removePendingSheet(Node* styleSheetCandidateNode)
|
| {
|
| DCHECK(styleSheetCandidateNode);
|
| - TreeScope* treeScope = isStyleElement(*styleSheetCandidateNode) ? &styleSheetCandidateNode->treeScope() : m_document.get();
|
| + TreeScope* treeScope = isStyleElement(*styleSheetCandidateNode) ? &styleSheetCandidateNode->treeScopeOrDocument() : m_document.get();
|
| if (styleSheetCandidateNode->inShadowIncludingDocument())
|
| markTreeScopeDirty(*treeScope);
|
|
|
| @@ -189,8 +189,8 @@ void StyleEngine::setNeedsActiveStyleUpdate(StyleSheet* sheet, StyleResolverUpda
|
| if (sheet && document().isActive()) {
|
| Node* node = sheet->ownerNode();
|
| if (node && node->inShadowIncludingDocument()) {
|
| - TreeScope& treeScope = isStyleElement(*node) ? node->treeScope() : *m_document;
|
| - DCHECK(isStyleElement(*node) || node->treeScope() == m_document);
|
| + TreeScope& treeScope = isStyleElement(*node) ? node->treeScopeOrDocument() : *m_document;
|
| + DCHECK(isStyleElement(*node) || node->treeScopeOrDocument() == m_document);
|
| markTreeScopeDirty(treeScope);
|
| }
|
| }
|
| @@ -203,7 +203,7 @@ void StyleEngine::addStyleSheetCandidateNode(Node* node)
|
| if (!node->inShadowIncludingDocument() || document().isDetached())
|
| return;
|
|
|
| - TreeScope& treeScope = isStyleElement(*node) ? node->treeScope() : *m_document;
|
| + TreeScope& treeScope = isStyleElement(*node) ? node->treeScopeOrDocument() : *m_document;
|
| DCHECK(isStyleElement(*node) || treeScope == m_document);
|
| DCHECK(!isXSLStyleSheet(*node));
|
| TreeScopeStyleSheetCollection* collection = ensureStyleSheetCollectionFor(treeScope);
|
| @@ -240,7 +240,7 @@ void StyleEngine::modifiedStyleSheetCandidateNode(Node* node)
|
| if (!node->inShadowIncludingDocument())
|
| return;
|
|
|
| - TreeScope& treeScope = isStyleElement(*node) ? node->treeScope() : *m_document;
|
| + TreeScope& treeScope = isStyleElement(*node) ? node->treeScopeOrDocument() : *m_document;
|
| DCHECK(isStyleElement(*node) || treeScope == m_document);
|
| markTreeScopeDirty(treeScope);
|
| resolverChanged(FullStyleUpdate);
|
|
|