aboutsummaryrefslogtreecommitdiffstats
path: root/components/layout_thread/lib.rs
diff options
context:
space:
mode:
Diffstat (limited to 'components/layout_thread/lib.rs')
-rw-r--r--components/layout_thread/lib.rs14
1 files changed, 13 insertions, 1 deletions
diff --git a/components/layout_thread/lib.rs b/components/layout_thread/lib.rs
index 839fac79006..b44bbb54b96 100644
--- a/components/layout_thread/lib.rs
+++ b/components/layout_thread/lib.rs
@@ -103,7 +103,7 @@ use std::time::Duration;
use style::animation::Animation;
use style::context::{QuirksMode, RegisteredSpeculativePainter, RegisteredSpeculativePainters};
use style::context::{SharedStyleContext, ThreadLocalStyleContextCreationInfo};
-use style::dom::{ShowSubtree, ShowSubtreeDataAndPrimaryValues, TElement, TNode};
+use style::dom::{ShowSubtree, ShowSubtreeDataAndPrimaryValues, TDocument, TElement, TNode};
use style::driver;
use style::error_reporting::RustLogReporter;
use style::global_style_data::{GLOBAL_STYLE_DATA, STYLE_THREAD_POOL};
@@ -1346,6 +1346,18 @@ impl LayoutThread {
}
}
+ debug!(
+ "Shadow roots in document {:?}",
+ document.shadow_roots().len()
+ );
+
+ // Flush shadow roots stylesheets if dirty.
+ document.flush_shadow_roots_stylesheets(
+ &self.stylist.device(),
+ document.quirks_mode(),
+ guards.author.clone(),
+ );
+
let restyles = document.drain_pending_restyles();
debug!("Draining restyles: {}", restyles.len());