Closed Bug 1558937 Opened 5 years ago Closed 5 years ago

Don't build duplicate display items for pagination

Categories

(Core :: Web Painting, task, P2)

task

Tracking

()

RESOLVED FIXED
mozilla69
Tracking Status
firefox69 --- fixed

People

(Reporter: mattwoodrow, Assigned: mattwoodrow)

Details

Attachments

(1 file)

We generally avoid creating duplicate items, since we need to uniquely identify them for retained display lists.

With the frame tree for paginated content, we can end up with an OOF frame being part of one page, but the placeholder for it on a different page. Since we have to descend through the placeholder to build display items for the OOF frame, we can end up needing to DL build though multiple pages (see BuildDisplayListForExtraPage) to create the content for a single page. When we're displaying multiple pages (for print preview), this can result in duplicate items.

Example frame tree:

Page1
    Block1
    AbsoluteList
        Block2
Page2
    Block3 (opacity: 0.5)
        Block4
        Placeholder(Block2)

DL:

Transform(Page1)
    BackgroundColor(Block1)
    Opacity(Block3)
        BackgroundColor(Block2)
Transform(Page2)
    Opacity(Block3)
        BackgroundColor(Block4)

In this case the opacity item for Block3 is duplicated, since it contains content belonging to both pages.

I think we can tag items that are built from extra pages with the page index of the destination page (tag the first Opacity with page 1) and use that index in the unique key computation.

Type: defect → task
Priority: -- → P2
Pushed by mwoodrow@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/c872cc627115
Don't allow duplicate items for printing. r=miko
Pushed by mwoodrow@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/69227743aff1
Don't allow duplicate items for printing. r=miko
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla69
Flags: needinfo?(matt.woodrow)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: