diff options
author | Martin Robinson <mrobinson@igalia.com> | 2020-06-05 12:06:25 +0200 |
---|---|---|
committer | Martin Robinson <mrobinson@igalia.com> | 2020-06-06 17:25:08 +0200 |
commit | 89855afa4daed56907b84daeb674066524e4352c (patch) | |
tree | a80dfbaa99b44bfcb049cd6182d70bf397ac04d0 /components/layout_2020/flow/float.rs | |
parent | 7df4655b604683aee5763696589b041024b264ce (diff) | |
download | servo-89855afa4daed56907b84daeb674066524e4352c.tar.gz servo-89855afa4daed56907b84daeb674066524e4352c.zip |
layout_2020: Tag fragments with their pseudo content type
This will allow us to answer queries and properly handle animations in
the future for fragments generated for pseudo content.
Diffstat (limited to 'components/layout_2020/flow/float.rs')
-rw-r--r-- | components/layout_2020/flow/float.rs | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/components/layout_2020/flow/float.rs b/components/layout_2020/flow/float.rs index 4a647f23071..da70838499f 100644 --- a/components/layout_2020/flow/float.rs +++ b/components/layout_2020/flow/float.rs @@ -3,12 +3,10 @@ * file, You can obtain one at https://mozilla.org/MPL/2.0/. */ use crate::context::LayoutContext; -use crate::dom_traversal::{Contents, NodeExt}; +use crate::dom_traversal::{Contents, NodeAndStyleInfo, NodeExt}; use crate::formatting_contexts::IndependentFormattingContext; use crate::sizing::ContentSizesRequest; use crate::style_ext::{ComputedValuesExt, DisplayInside}; -use servo_arc::Arc; -use style::properties::ComputedValues; use style::values::specified::text::TextDecorationLine; #[derive(Debug, Serialize)] @@ -30,17 +28,15 @@ impl FloatContext { impl FloatBox { pub fn construct<'dom>( context: &LayoutContext, - node: impl NodeExt<'dom>, - style: Arc<ComputedValues>, + info: &NodeAndStyleInfo<impl NodeExt<'dom>>, display_inside: DisplayInside, contents: Contents, ) -> Self { - let content_sizes = ContentSizesRequest::inline_if(!style.inline_size_is_length()); + let content_sizes = ContentSizesRequest::inline_if(!info.style.inline_size_is_length()); Self { contents: IndependentFormattingContext::construct( context, - node, - style, + info, display_inside, contents, content_sizes, |