diff options
author | bors-servo <servo-ops@mozilla.com> | 2020-03-28 13:37:31 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-28 13:37:31 -0400 |
commit | 15d8c6058bb5fd21036cb35500a0c2f23a9ef7f7 (patch) | |
tree | fde1850c9fe7f9050d0342a7c01f76f39985040f /components/layout/fragment.rs | |
parent | e69de9bc9cf5cdd29d1c392c613bc1c1ad4815bf (diff) | |
parent | dba6a635e5df980b2837495aae59711739c23716 (diff) | |
download | servo-15d8c6058bb5fd21036cb35500a0c2f23a9ef7f7.tar.gz servo-15d8c6058bb5fd21036cb35500a0c2f23a9ef7f7.zip |
Auto merge of #26048 - nox:layout-2020-transparent-data, r=jdm
Give a lifetime parameter to LayoutDom
Diffstat (limited to 'components/layout/fragment.rs')
-rw-r--r-- | components/layout/fragment.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/components/layout/fragment.rs b/components/layout/fragment.rs index d074c300e2f..289dc3f3094 100644 --- a/components/layout/fragment.rs +++ b/components/layout/fragment.rs @@ -411,10 +411,10 @@ impl ImageFragmentInfo { /// /// FIXME(pcwalton): The fact that image fragments store the cache in the fragment makes little /// sense to me. - pub fn new<N: ThreadSafeLayoutNode>( + pub fn new<'dom>( url: Option<ServoUrl>, density: Option<f64>, - node: &N, + node: &impl ThreadSafeLayoutNode<'dom>, layout_context: &LayoutContext, ) -> ImageFragmentInfo { // First use any image data present in the element... @@ -488,7 +488,7 @@ pub struct IframeFragmentInfo { impl IframeFragmentInfo { /// Creates the information specific to an iframe fragment. - pub fn new<N: ThreadSafeLayoutNode>(node: &N) -> IframeFragmentInfo { + pub fn new<'dom>(node: &impl ThreadSafeLayoutNode<'dom>) -> IframeFragmentInfo { let browsing_context_id = node.iframe_browsing_context_id(); let pipeline_id = node.iframe_pipeline_id(); IframeFragmentInfo { @@ -642,7 +642,7 @@ pub struct TableColumnFragmentInfo { impl TableColumnFragmentInfo { /// Create the information specific to an table column fragment. - pub fn new<N: ThreadSafeLayoutNode>(node: &N) -> TableColumnFragmentInfo { + pub fn new<'dom>(node: &impl ThreadSafeLayoutNode<'dom>) -> TableColumnFragmentInfo { let element = node.as_element().unwrap(); let span = element .get_attr(&ns!(), &local_name!("span")) @@ -663,8 +663,8 @@ pub struct TruncatedFragmentInfo { impl Fragment { /// Constructs a new `Fragment` instance. - pub fn new<N: ThreadSafeLayoutNode>( - node: &N, + pub fn new<'dom>( + node: &impl ThreadSafeLayoutNode<'dom>, specific: SpecificFragmentInfo, ctx: &LayoutContext, ) -> Fragment { |