Closed Bug 1622008 Opened 4 years ago Closed 4 years ago

Simplify some APIs related to creating continuing frames

Categories

(Core :: Layout, task)

task
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla76
Tracking Status
firefox76 --- fixed

People

(Reporter: TYLin, Assigned: TYLin)

Details

Attachments

(3 files)

I notice some refactoring possibilities while working on flex fragmentation.

The nsPresContext* argument of
nsCSSFrameConstructor::CreateContinuingFrame() is used only to get
PresShell. However, mPresShell is already cached in
nsCSSFrameConstructor (via its base class nsFrameManager).

By doing so, we can remove now-unused nsPresContext* or PresShell* from
some continuing-frame-creation methods' argument list in the next part.

Depends on D66598

Both PresShell() and PresContext() are cached in nsIFrame. This
simplifies the setup for the callers to
nsCSSFrameConstructor::CreateContinuingFrame().

Depends on D66599

Pushed by aethanyc@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/2b848bc7334e
Part 1 - Revise nsFrameManager's documentation. r=dholbert
https://hg.mozilla.org/integration/autoland/rev/965a81a5c3a9
Part 2 - Use cached mPresShell in nsCSSFrameConstructor. r=dholbert
https://hg.mozilla.org/integration/autoland/rev/8594a9e87c7f
Part 3 - Remove nsPresContext* and PresShell* from the argument list of some continuing-frame-creation methods. r=dholbert
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: