Closed Bug 1783402 Opened 2 years ago Closed 2 years ago

Make result of getter methods of `EditorDOMPointBase` and `SplitRangeOffFromNodeResult` templated

Categories

(Core :: DOM: Editor, enhancement, P2)

enhancement

Tracking

()

RESOLVED FIXED
105 Branch
Tracking Status
firefox105 --- fixed

People

(Reporter: masayuki, Assigned: masayuki)

References

Details

Attachments

(3 files)

It's not reasonable to add getter methods such as Get*AsElement(), Get*AsText()... Instead, they can be Get*As<Element>(), Get*As<Text>(), etc.

We'll need the version to return dom::Text* in coming patches for bug 1735608.
For avoiding the class to have a lot of getters, we should make result of the
getters templated.

Depends on D153838

Similar to the previous patch, and for consistency between editor helper
classes, we should make result of getter methods of EditorDOMPointBase too.

Depends on D153840

Pushed by masayuki@d-toybox.com: https://hg.mozilla.org/integration/autoland/rev/378289e8030b part 1: Make result of the getter methods of `SplitRangeOffFromNodeResult` templated r=m_kato https://hg.mozilla.org/integration/autoland/rev/22de73c7fb44 part 2: Make result of safe getter methods of `EditorDOMPointBase` templated r=m_kato https://hg.mozilla.org/integration/autoland/rev/18bbc1d50e89 part 3: Make result of unsafe getter methods of `EditorDOMPointBase` templated r=m_kato
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 105 Branch
Regressions: 1785311
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: