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

Unified Diff: third_party/WebKit/Source/core/dom/StyleEngine.cpp

Issue 2546393002: Make setNeedsActiveStyleUpdate mark treescope dirty only. (Closed)
Patch Set: Rebased Created 4 years 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/dom/StyleEngine.cpp
diff --git a/third_party/WebKit/Source/core/dom/StyleEngine.cpp b/third_party/WebKit/Source/core/dom/StyleEngine.cpp
index 4f43661a933f6f53667016f3a3e4ce86300b14ef..fca51cb7fe1b23c3ed2f54a17b62aa5a15f9faf1 100644
--- a/third_party/WebKit/Source/core/dom/StyleEngine.cpp
+++ b/third_party/WebKit/Source/core/dom/StyleEngine.cpp
@@ -185,23 +185,11 @@ void StyleEngine::removePendingSheet(Node& styleSheetCandidateNode,
document().didRemoveAllPendingStylesheet();
}
-void StyleEngine::setNeedsActiveStyleUpdate(
- StyleSheet* sheet,
- StyleResolverUpdateMode updateMode) {
- // resolverChanged() is called for inactive non-master documents because
- // import documents are inactive documents. resolverChanged() for imports
- // will call resolverChanged() for the master document and update the active
- // stylesheets including the ones from the import.
+void StyleEngine::setNeedsActiveStyleUpdate(TreeScope& treeScope) {
if (!document().isActive() && isMaster())
return;
- if (sheet && document().isActive()) {
- Node* node = sheet->ownerNode();
- if (node && node->isConnected())
- markTreeScopeDirty(node->treeScope());
- }
-
- resolverChanged(updateMode);
+ markTreeScopeDirty(treeScope);
}
void StyleEngine::addStyleSheetCandidateNode(Node& node) {
« no previous file with comments | « third_party/WebKit/Source/core/dom/StyleEngine.h ('k') | third_party/WebKit/Source/core/html/HTMLLinkElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698