mirror of
https://github.com/servo/servo.git
synced 2025-08-06 06:00:15 +01:00
Eliminate duplicate Layout DOM wrappers
There are duplicate sets of Layout DOM wrappers: one for Layout 2013 and one for Layout 2020. As part of cleaning up and simplifying the wrappers, this change parameterizes them on the specific layout data they contain. This allows them to be shared again. In addition, various small cleanups are included. Fixes #29691.
This commit is contained in:
parent
ab0d462c83
commit
2d31d4301d
14 changed files with 1035 additions and 2362 deletions
|
@ -6,6 +6,7 @@ use crate::cell::ArcRefCell;
|
|||
use crate::flexbox::FlexLevelBox;
|
||||
use crate::flow::inline::InlineLevelBox;
|
||||
use crate::flow::BlockLevelBox;
|
||||
use script_layout_interface::wrapper_traits::LayoutDataTrait;
|
||||
|
||||
#[derive(Default)]
|
||||
pub struct LayoutDataForElement {
|
||||
|
@ -20,3 +21,5 @@ pub(super) enum LayoutBox {
|
|||
InlineLevel(ArcRefCell<InlineLevelBox>),
|
||||
FlexLevel(ArcRefCell<FlexLevelBox>),
|
||||
}
|
||||
|
||||
impl LayoutDataTrait for LayoutDataForElement {}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue