diff options
Diffstat (limited to 'components/script/dom/shadowroot.rs')
-rw-r--r-- | components/script/dom/shadowroot.rs | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/components/script/dom/shadowroot.rs b/components/script/dom/shadowroot.rs index 71db09f4671..6dd2ee122e6 100644 --- a/components/script/dom/shadowroot.rs +++ b/components/script/dom/shadowroot.rs @@ -240,12 +240,10 @@ impl ShadowRootMethods for ShadowRoot { #[allow(unsafe_code)] pub trait LayoutShadowRootHelpers<'dom> { - unsafe fn get_host_for_layout(&self) -> LayoutDom<'dom, Element>; - unsafe fn get_style_data_for_layout<'a, E: TElement>( - &self, - ) -> &'a AuthorStyles<StyleSheetInDocument>; + unsafe fn get_host_for_layout(self) -> LayoutDom<'dom, Element>; + unsafe fn get_style_data_for_layout(self) -> &'dom AuthorStyles<StyleSheetInDocument>; unsafe fn flush_stylesheets<E: TElement>( - &self, + self, device: &Device, quirks_mode: QuirksMode, guard: &SharedRwLockReadGuard, @@ -255,7 +253,7 @@ pub trait LayoutShadowRootHelpers<'dom> { impl<'dom> LayoutShadowRootHelpers<'dom> for LayoutDom<'dom, ShadowRoot> { #[inline] #[allow(unsafe_code)] - unsafe fn get_host_for_layout(&self) -> LayoutDom<'dom, Element> { + unsafe fn get_host_for_layout(self) -> LayoutDom<'dom, Element> { (*self.unsafe_get()) .host .get_inner_as_layout() @@ -264,16 +262,14 @@ impl<'dom> LayoutShadowRootHelpers<'dom> for LayoutDom<'dom, ShadowRoot> { #[inline] #[allow(unsafe_code)] - unsafe fn get_style_data_for_layout<'a, E: TElement>( - &self, - ) -> &'a AuthorStyles<StyleSheetInDocument> { + unsafe fn get_style_data_for_layout(self) -> &'dom AuthorStyles<StyleSheetInDocument> { (*self.unsafe_get()).author_styles.borrow_for_layout() } #[inline] #[allow(unsafe_code)] unsafe fn flush_stylesheets<E: TElement>( - &self, + self, device: &Device, quirks_mode: QuirksMode, guard: &SharedRwLockReadGuard, |