mirror of
https://github.com/servo/servo.git
synced 2025-07-22 14:53:49 +01:00
Remove use of some other unstable features
This commit is contained in:
parent
7861b0be79
commit
7f975c3d5d
4 changed files with 11 additions and 8 deletions
|
@ -303,7 +303,11 @@ impl InlineFormattingContext {
|
|||
panic!("display:none does not generate an abspos box")
|
||||
},
|
||||
};
|
||||
let hoisted_box = box_.clone().to_hoisted(initial_start_corner, tree_rank);
|
||||
let hoisted_box = AbsolutelyPositionedBox::to_hoisted(
|
||||
box_.clone(),
|
||||
initial_start_corner,
|
||||
tree_rank,
|
||||
);
|
||||
let hoisted_fragment = hoisted_box.fragment.clone();
|
||||
ifc.push_hoisted_box_to_positioning_context(hoisted_box);
|
||||
ifc.current_nesting_level.fragments_so_far.push(
|
||||
|
@ -786,7 +790,7 @@ impl TextRun {
|
|||
glyphs,
|
||||
text_decoration_line: ifc.current_nesting_level.text_decoration_line,
|
||||
}));
|
||||
if runs.is_empty() {
|
||||
if runs.as_slice().is_empty() {
|
||||
break;
|
||||
} else {
|
||||
// New line
|
||||
|
|
|
@ -315,7 +315,8 @@ impl BlockLevelBox {
|
|||
))
|
||||
},
|
||||
BlockLevelBox::OutOfFlowAbsolutelyPositionedBox(box_) => {
|
||||
let hoisted_box = box_.clone().to_hoisted(Vec2::zero(), tree_rank);
|
||||
let hoisted_box =
|
||||
AbsolutelyPositionedBox::to_hoisted(box_.clone(), Vec2::zero(), tree_rank);
|
||||
let hoisted_fragment = hoisted_box.fragment.clone();
|
||||
positioning_context.push(hoisted_box);
|
||||
Fragment::AbsoluteOrFixedPositioned(AbsoluteOrFixedPositionedFragment {
|
||||
|
|
|
@ -3,8 +3,6 @@
|
|||
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
|
||||
|
||||
#![deny(unsafe_code)]
|
||||
#![feature(arbitrary_self_types)]
|
||||
#![feature(exact_size_is_empty)]
|
||||
|
||||
#[macro_use]
|
||||
extern crate serde;
|
||||
|
|
|
@ -100,7 +100,7 @@ impl AbsolutelyPositionedBox {
|
|||
}
|
||||
|
||||
pub(crate) fn to_hoisted(
|
||||
self: Arc<Self>,
|
||||
self_: Arc<Self>,
|
||||
initial_start_corner: Vec2<Length>,
|
||||
tree_rank: usize,
|
||||
) -> HoistedAbsolutelyPositionedBox {
|
||||
|
@ -124,7 +124,7 @@ impl AbsolutelyPositionedBox {
|
|||
}
|
||||
}
|
||||
|
||||
let box_offsets = self.contents.style.box_offsets();
|
||||
let box_offsets = self_.contents.style.box_offsets();
|
||||
HoistedAbsolutelyPositionedBox {
|
||||
tree_rank,
|
||||
box_offsets: Vec2 {
|
||||
|
@ -140,7 +140,7 @@ impl AbsolutelyPositionedBox {
|
|||
),
|
||||
},
|
||||
fragment: ArcRefCell::new(None),
|
||||
absolutely_positioned_box: self,
|
||||
absolutely_positioned_box: self_,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue