mirror of
https://github.com/servo/servo.git
synced 2025-08-03 12:40:06 +01:00
auto merge of #3839 : pcwalton/servo/fewer-moves-in-dls, r=glennw
These were showing up in the profile. r? @glennw
This commit is contained in:
commit
651ef60b1c
4 changed files with 96 additions and 99 deletions
|
@ -743,11 +743,10 @@ impl LayoutTask {
|
|||
debug!("Done building display list. Display List = {}",
|
||||
flow::base(layout_root.deref()).display_list);
|
||||
|
||||
let root_display_list =
|
||||
mem::replace(&mut flow::mut_base(layout_root.deref_mut()).display_list,
|
||||
DisplayList::new());
|
||||
root_display_list.debug();
|
||||
let display_list = Arc::new(root_display_list.flatten(ContentStackingLevel));
|
||||
flow::mut_base(&mut *layout_root).display_list.flatten(ContentStackingLevel);
|
||||
let display_list =
|
||||
Arc::new(mem::replace(&mut flow::mut_base(&mut *layout_root).display_list,
|
||||
DisplayList::new()));
|
||||
|
||||
// FIXME(pcwalton): This is really ugly and can't handle overflow: scroll. Refactor
|
||||
// it with extreme prejudice.
|
||||
|
@ -787,7 +786,7 @@ impl LayoutTask {
|
|||
scroll_policy: Scrollable,
|
||||
};
|
||||
|
||||
rw_data.display_list = Some(display_list.clone());
|
||||
rw_data.display_list = Some(display_list);
|
||||
|
||||
// TODO(pcwalton): Eventually, when we have incremental reflow, this will have to
|
||||
// be smarter in order to handle retained layer contents properly from reflow to
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue