Create a solid rectangle display list entry for the page background.

This commit is contained in:
Josh Matthews 2019-06-10 17:09:44 -04:00
parent e57e2121b2
commit 10ab466e5d
4 changed files with 37 additions and 11 deletions

View file

@ -1138,8 +1138,13 @@ impl LayoutThread {
rw_data.display_list.is_none()
{
if reflow_goal.needs_display_list() {
let mut build_state =
sequential::build_display_list_for_subtree(layout_root, layout_context);
let background_color = get_root_flow_background_color(layout_root);
let mut build_state = sequential::build_display_list_for_subtree(
layout_root,
layout_context,
background_color,
data.page_clip_rect.size,
);
debug!("Done building display list.");
@ -1255,7 +1260,7 @@ impl LayoutThread {
let mut txn = webrender_api::Transaction::new();
txn.set_display_list(
webrender_api::Epoch(epoch.0),
Some(get_root_flow_background_color(layout_root)),
None,
viewport_size,
builder.finalize(),
true,