Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Gecko Bug 1793873] Make HTMLEditor::DoSplitNode stop assuming that joining nodes are in same parent #36450

Merged
merged 1 commit into from Oct 14, 2022

Conversation

moz-wptsync-bot
Copy link
Collaborator

Between splitting a node and undoing it, web apps can move split nodes anywhere.
Therefore, it shouldn't assume they are always in same parent node, and
RangeUpdater::SelAdjJoinNodes needs to handle it correctly.

Unfortunately, RangeUpdater::SelAdjJoinNodes cannot handle nested cases
correctly, e.g., right node was in aRemovedContent or right node was in
the container of aStartOfRightContent.GetContainer(). However, it's not
a new regression, and such complicated situation breaks undoing anyway.
Therefore, I think that we don't need to care about it for now.

Differential Revision: https://phabricator.services.mozilla.com/D159230

bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1793873
gecko-commit: 26035e8182733cba68e97d26b21f0934494dc727
gecko-reviewers: m_kato

…n same parent

Between splitting a node and undoing it, web apps can move split nodes anywhere.
Therefore, it shouldn't assume they are always in same parent node, and
`RangeUpdater::SelAdjJoinNodes` needs to handle it correctly.

Unfortunately, `RangeUpdater::SelAdjJoinNodes` cannot handle nested cases
correctly, e.g., right node was in `aRemovedContent` or right node was in
the container of `aStartOfRightContent.GetContainer()`.  However, it's not
a new regression, and such complicated situation breaks undoing anyway.
Therefore, I think that we don't need to care about it for now.

Differential Revision: https://phabricator.services.mozilla.com/D159230

bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1793873
gecko-commit: 26035e8182733cba68e97d26b21f0934494dc727
gecko-reviewers: m_kato
Copy link
Collaborator

@wpt-pr-bot wpt-pr-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The review process for this patch is being conducted in the Firefox project.

@moz-wptsync-bot moz-wptsync-bot merged commit 5734250 into master Oct 14, 2022
@moz-wptsync-bot moz-wptsync-bot deleted the gecko/1793873 branch October 14, 2022 10:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants