mirror of
https://github.com/servo/servo.git
synced 2025-08-07 06:25:32 +01:00
Make AbsolutelyPositionedBox be 'static
This commit is contained in:
parent
7ade924683
commit
c3932185ec
7 changed files with 42 additions and 48 deletions
|
@ -50,7 +50,7 @@ pub(crate) enum BlockLevelBox {
|
|||
style: Arc<ComputedValues>,
|
||||
contents: BlockContainer,
|
||||
},
|
||||
OutOfFlowAbsolutelyPositionedBox(AbsolutelyPositionedBox),
|
||||
OutOfFlowAbsolutelyPositionedBox(Arc<AbsolutelyPositionedBox>),
|
||||
OutOfFlowFloatBox(FloatBox),
|
||||
Independent(IndependentFormattingContext),
|
||||
}
|
||||
|
@ -65,10 +65,10 @@ struct FlowLayout {
|
|||
struct CollapsibleWithParentStartMargin(bool);
|
||||
|
||||
impl BlockFormattingContext {
|
||||
pub(super) fn layout<'a>(
|
||||
&'a self,
|
||||
pub(super) fn layout(
|
||||
&self,
|
||||
layout_context: &LayoutContext,
|
||||
positioning_context: &mut PositioningContext<'a>,
|
||||
positioning_context: &mut PositioningContext,
|
||||
containing_block: &ContainingBlock,
|
||||
tree_rank: usize,
|
||||
) -> IndependentLayout {
|
||||
|
@ -101,10 +101,10 @@ impl BlockFormattingContext {
|
|||
}
|
||||
|
||||
impl BlockContainer {
|
||||
fn layout<'a>(
|
||||
&'a self,
|
||||
fn layout(
|
||||
&self,
|
||||
layout_context: &LayoutContext,
|
||||
positioning_context: &mut PositioningContext<'a>,
|
||||
positioning_context: &mut PositioningContext,
|
||||
containing_block: &ContainingBlock,
|
||||
tree_rank: usize,
|
||||
float_context: Option<&mut FloatContext>,
|
||||
|
@ -130,10 +130,10 @@ impl BlockContainer {
|
|||
}
|
||||
}
|
||||
|
||||
fn layout_block_level_children<'a>(
|
||||
fn layout_block_level_children(
|
||||
layout_context: &LayoutContext,
|
||||
positioning_context: &mut PositioningContext<'a>,
|
||||
child_boxes: &'a [Arc<BlockLevelBox>],
|
||||
positioning_context: &mut PositioningContext,
|
||||
child_boxes: &[Arc<BlockLevelBox>],
|
||||
containing_block: &ContainingBlock,
|
||||
tree_rank: usize,
|
||||
mut float_context: Option<&mut FloatContext>,
|
||||
|
@ -256,10 +256,10 @@ fn layout_block_level_children<'a>(
|
|||
}
|
||||
|
||||
impl BlockLevelBox {
|
||||
fn layout<'a>(
|
||||
&'a self,
|
||||
fn layout(
|
||||
&self,
|
||||
layout_context: &LayoutContext,
|
||||
positioning_context: &mut PositioningContext<'a>,
|
||||
positioning_context: &mut PositioningContext,
|
||||
containing_block: &ContainingBlock,
|
||||
tree_rank: usize,
|
||||
float_context: Option<&mut FloatContext>,
|
||||
|
@ -338,13 +338,13 @@ enum NonReplacedContents<'a> {
|
|||
|
||||
/// https://drafts.csswg.org/css2/visudet.html#blockwidth
|
||||
/// https://drafts.csswg.org/css2/visudet.html#normal-block
|
||||
fn layout_in_flow_non_replaced_block_level<'a>(
|
||||
fn layout_in_flow_non_replaced_block_level(
|
||||
layout_context: &LayoutContext,
|
||||
positioning_context: &mut PositioningContext<'a>,
|
||||
positioning_context: &mut PositioningContext,
|
||||
containing_block: &ContainingBlock,
|
||||
tag: OpaqueNode,
|
||||
style: &Arc<ComputedValues>,
|
||||
block_level_kind: NonReplacedContents<'a>,
|
||||
block_level_kind: NonReplacedContents,
|
||||
tree_rank: usize,
|
||||
float_context: Option<&mut FloatContext>,
|
||||
) -> BoxFragment {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue