aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/shadowroot.rs
diff options
context:
space:
mode:
authorOriol Brufau <obrufau@igalia.com>2023-05-12 19:35:00 +0200
committerOriol Brufau <obrufau@igalia.com>2023-05-16 13:00:18 +0200
commit60e206143c7346b2255c9c1a6af745d4b0c77985 (patch)
tree8338dbe12d82a692c61738db3bdc26120e6a7d59 /components/script/dom/shadowroot.rs
parent060d74ba3bcccf8ace74ac8d00c7589783a2a45d (diff)
downloadservo-60e206143c7346b2255c9c1a6af745d4b0c77985.tar.gz
servo-60e206143c7346b2255c9c1a6af745d4b0c77985.zip
Further changes required by Servo
Diffstat (limited to 'components/script/dom/shadowroot.rs')
-rw-r--r--components/script/dom/shadowroot.rs12
1 files changed, 4 insertions, 8 deletions
diff --git a/components/script/dom/shadowroot.rs b/components/script/dom/shadowroot.rs
index c70c13d8cef..1fa9faae287 100644
--- a/components/script/dom/shadowroot.rs
+++ b/components/script/dom/shadowroot.rs
@@ -19,15 +19,13 @@ use crate::dom::stylesheetlist::{StyleSheetList, StyleSheetListOwner};
use crate::dom::window::Window;
use crate::stylesheet_set::StylesheetSetRef;
use dom_struct::dom_struct;
-use selectors::context::QuirksMode;
use servo_arc::Arc;
use servo_atoms::Atom;
use style::author_styles::AuthorStyles;
use style::dom::TElement;
-use style::media_queries::Device;
use style::shared_lock::SharedRwLockReadGuard;
use style::stylesheets::Stylesheet;
-use style::stylist::CascadeData;
+use style::stylist::{CascadeData, Stylist};
/// Whether a shadow root hosts an User Agent widget.
#[derive(JSTraceable, MallocSizeOf, PartialEq)]
@@ -245,8 +243,7 @@ pub trait LayoutShadowRootHelpers<'dom> {
fn get_style_data_for_layout(self) -> &'dom CascadeData;
unsafe fn flush_stylesheets<E: TElement>(
self,
- device: &Device,
- quirks_mode: QuirksMode,
+ stylist: &mut Stylist,
guard: &SharedRwLockReadGuard,
);
}
@@ -277,13 +274,12 @@ impl<'dom> LayoutShadowRootHelpers<'dom> for LayoutDom<'dom, ShadowRoot> {
#[allow(unsafe_code)]
unsafe fn flush_stylesheets<E: TElement>(
self,
- device: &Device,
- quirks_mode: QuirksMode,
+ stylist: &mut Stylist,
guard: &SharedRwLockReadGuard,
) {
let author_styles = self.unsafe_get().author_styles.borrow_mut_for_layout();
if author_styles.stylesheets.dirty() {
- author_styles.flush::<E>(device, quirks_mode, guard);
+ author_styles.flush::<E>(stylist, guard);
}
}
}