diff options
author | bors-servo <infra@servo.org> | 2023-05-19 22:49:36 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-19 22:49:36 +0200 |
commit | 2426a38a4d11615d71c34649b83436aa1f109260 (patch) | |
tree | a5c682e2f3d93813aa5e42c8f50f3f6512b73574 /components/script/layout_dom/document.rs | |
parent | 71c5bb02b41b8d98b1612563558c2c14b3e20b1a (diff) | |
parent | dbb92b99ad359634e8b84417b8264f84bfc5d056 (diff) | |
download | servo-2426a38a4d11615d71c34649b83436aa1f109260.tar.gz servo-2426a38a4d11615d71c34649b83436aa1f109260.zip |
Auto merge of #29748 - Loirooriol:sync, r=mrobinson
Backport several style changes from Gecko
<!-- Please describe your changes on the following line: -->
---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [ ] These changes fix #___ (GitHub issue number if applicable)
<!-- Either: -->
- [X] There are tests for these changes OR
- [ ] These changes do not require tests because ___
<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->
<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
Diffstat (limited to 'components/script/layout_dom/document.rs')
-rw-r--r-- | components/script/layout_dom/document.rs | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/components/script/layout_dom/document.rs b/components/script/layout_dom/document.rs index e723f731cab..392c1686f97 100644 --- a/components/script/layout_dom/document.rs +++ b/components/script/layout_dom/document.rs @@ -12,10 +12,10 @@ use script_layout_interface::wrapper_traits::LayoutDataTrait; use selectors::matching::QuirksMode; use std::marker::PhantomData; use style::dom::{TDocument, TNode}; -use style::media_queries::Device; use style::shared_lock::{ SharedRwLock as StyleSharedRwLock, SharedRwLockReadGuard as StyleSharedRwLockReadGuard, }; +use style::stylist::Stylist; // A wrapper around documents that ensures ayout can only ever access safe properties. pub struct ServoLayoutDocument<'dom, LayoutDataType: LayoutDataTrait> { @@ -90,8 +90,7 @@ impl<'ld, LayoutDataType: LayoutDataTrait> ServoLayoutDocument<'ld, LayoutDataTy pub fn flush_shadow_roots_stylesheets( &self, - device: &Device, - quirks_mode: QuirksMode, + stylist: &mut Stylist, guard: &StyleSharedRwLockReadGuard, ) { unsafe { @@ -100,7 +99,7 @@ impl<'ld, LayoutDataType: LayoutDataTrait> ServoLayoutDocument<'ld, LayoutDataTy } self.document.flush_shadow_roots_stylesheets(); for shadow_root in self.shadow_roots() { - shadow_root.flush_stylesheets(device, quirks_mode, guard); + shadow_root.flush_stylesheets(stylist, guard); } } } |