Closed Bug 1628043 Opened 5 years ago Closed 5 years ago

Some const-correctness improvements in layout code

Categories

(Core :: Layout, task, P3)

task

Tracking

()

RESOLVED FIXED
mozilla77
Tracking Status
firefox77 --- fixed

People

(Reporter: botond, Assigned: botond)

Details

Attachments

(2 files)

No description provided.

This allows us to have a single const_cast inside GetFramesForArea, and
avoid several callers of these functions (which, as of bug 1556556,
get a const nsIFrame* from RelativeTo inputs) having to const_cast.

This is a partial attempt to remove the const_cast in GetFramesForArea.
I had to abandon the larger attempt because propagating the const into
nsDisplayListBuilder::mReferenceFrame is not feasible (since it sets
frame properties for caching purposes during display list building).
However, we might as well land the partial attempt as it still improves
const-correctness.

Depends on D70068

Pushed by bballo@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/315243cedc42 Have GetFrameForPoint and GetFramesForArea take a const nsIFrame*. r=tnikkel https://hg.mozilla.org/integration/autoland/rev/0e8b1e12a459 Have EnterPresShell and LeavePresShell take const nsIFrame*. r=tnikkel
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla77
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: