diff options
author | bors-servo <servo-ops@mozilla.com> | 2020-06-10 01:33:34 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-06-10 01:33:34 -0400 |
commit | 554af02ab44f6dc96b8ebc570cdb01708a5a44bb (patch) | |
tree | ea05dd40bbf09a2c2e9c15c62933a7c1732d8cad /components/layout_2020/flow/mod.rs | |
parent | 1a561242cfca27b51d31bf63509cbc95044b69d4 (diff) | |
parent | e975d24c4bb705f7897edde83f61725655399e8f (diff) | |
download | servo-554af02ab44f6dc96b8ebc570cdb01708a5a44bb.tar.gz servo-554af02ab44f6dc96b8ebc570cdb01708a5a44bb.zip |
Auto merge of #26833 - servo:layout-2020-arcrefcell-abspos, r=SimonSapin
Store abspos boxes in a RefCell too
We want to mutate them when lazily computing their content sizes, but they
are behind an Arc for the hoisting infra, so it also needs its own layer
of inner mutability.
Diffstat (limited to 'components/layout_2020/flow/mod.rs')
-rw-r--r-- | components/layout_2020/flow/mod.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/components/layout_2020/flow/mod.rs b/components/layout_2020/flow/mod.rs index be56a3e2226..4f22b857e84 100644 --- a/components/layout_2020/flow/mod.rs +++ b/components/layout_2020/flow/mod.rs @@ -52,7 +52,7 @@ pub(crate) enum BlockLevelBox { style: Arc<ComputedValues>, contents: BlockContainer, }, - OutOfFlowAbsolutelyPositionedBox(Arc<AbsolutelyPositionedBox>), + OutOfFlowAbsolutelyPositionedBox(ArcRefCell<AbsolutelyPositionedBox>), OutOfFlowFloatBox(FloatBox), Independent(IndependentFormattingContext), } @@ -322,7 +322,7 @@ impl BlockLevelBox { positioning_context.push(hoisted_box); Fragment::AbsoluteOrFixedPositioned(AbsoluteOrFixedPositionedFragment { hoisted_fragment, - position: box_.contents.style.clone_position(), + position: box_.borrow().contents.style.clone_position(), }) }, BlockLevelBox::OutOfFlowFloatBox(_box_) => { |