Open Bug 1670037 Opened 1 year ago Updated 8 months ago

Get rid of the DeferredTask code in print.js

Categories

(Toolkit :: Printing, enhancement, P2)

enhancement

Tracking

()

People

(Reporter: jwatt, Unassigned)

Details

(Keywords: perf, Whiteboard: [print2020] [old-ui-] )

This code can result in poor performance:

https://searchfox.org/mozilla-central/rev/f82d5c549f046cb64ce5602bfd894b7ae807c8f8/toolkit/components/printing/content/print.js#259-261

If layout of the print preview document takes a long time and the user want to make multiple settings changes, they may have to wait multiple layouts before the preview document is ready. Try making multiple changes to this wikipedia article, for example.

Since Emilio fixed bug 1659432, I believe we no longer need to wait for settings changes to take affect before the frontend can tell the platform code to apply new settings.

Emilio, correct me if I'm wrong on that. I guess if layout is really slow and the user fires a whole series of settings changes we could end up with a bunch of redundant IPDL messages that we'll process sequentially. Hmm, I'm not sure what we can do about that.

Flags: needinfo?(emilio)
Keywords: perf

Yeah, I think that's right. The main benefit is not doing too much work if we can't keep up with the settings updates...

Flags: needinfo?(emilio)
Whiteboard: [print2020_v83][old-ui-] → [print2020_v84][old-ui-]
Whiteboard: [print2020_v84][old-ui-] → [print2020_v85][old-ui-]

(Moving bugs to 86, part 1.)

Whiteboard: [print2020_v85][old-ui-] → [print2020_v86][old-ui-]

Moving things to 88, cause we're mostly on Proton these days…

Whiteboard: [print2020_v86][old-ui-] → [print2020_v88] [old-ui-]
Whiteboard: [print2020_v88] [old-ui-] → [print2020] [old-ui-]
You need to log in before you can comment on or make changes to this bug.