mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
Separate stacking context collection and display list building state
These are two different passes during layout, but previously they shared a state object. While some of the members are the same, many are different so we separate them out into two separate objects. We also change the HashMaps of these state objects to use the FnvHashMap.
This commit is contained in:
parent
bffe158fa4
commit
ee46bc57ed
15 changed files with 153 additions and 94 deletions
|
@ -10,7 +10,7 @@ use ServoArc;
|
|||
use app_units::Au;
|
||||
use block::BlockFlow;
|
||||
use context::LayoutContext;
|
||||
use display_list_builder::DisplayListBuildState;
|
||||
use display_list_builder::{DisplayListBuildState, StackingContextCollectionState};
|
||||
use euclid::{Point2D, Vector2D};
|
||||
use floats::FloatKind;
|
||||
use flow::{Flow, FlowClass, OpaqueFlow, mut_base, FragmentationContext};
|
||||
|
@ -189,7 +189,7 @@ impl Flow for MulticolFlow {
|
|||
self.block_flow.build_display_list(state);
|
||||
}
|
||||
|
||||
fn collect_stacking_contexts(&mut self, state: &mut DisplayListBuildState) {
|
||||
fn collect_stacking_contexts(&mut self, state: &mut StackingContextCollectionState) {
|
||||
self.block_flow.collect_stacking_contexts(state);
|
||||
}
|
||||
|
||||
|
@ -279,7 +279,7 @@ impl Flow for MulticolColumnFlow {
|
|||
self.block_flow.build_display_list(state);
|
||||
}
|
||||
|
||||
fn collect_stacking_contexts(&mut self, state: &mut DisplayListBuildState) {
|
||||
fn collect_stacking_contexts(&mut self, state: &mut StackingContextCollectionState) {
|
||||
self.block_flow.collect_stacking_contexts(state);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue