Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
part 1: Make
AutoMoveOneLineHandler
make AutoRangeArray
work with…
… `BlockInlineCheck::UseComputedDisplayOutsideStyle `AutoMoveOneLineHandler` uses `AutoRangeArray` API for block level edit sub-actions. Therefore, the source line is computed with `BlockInlineCheck::UseHTMLDefaultStyle`. However, the deletion handler works with `BlockInlineCheck::UseComputedDisplayOutsideStyle`. Therefore, `AutoMoveOneLineHandler` may try to move different range. In the reported test case, it tries to move all content under the `<body>` into the `<a display="table-header-group">` which is contained in the range. Therefore, the `movedContentRange` check fails after the destination becomes into an orphan node which was removed to move. This patch renames the API and adds a `BlockInlineCheck` parameter to work with both ways and makes `AutoMoveOneLineHandler` specify `BlockInlineCheck::UseComputedDisplayOutsideStyle` as same as the other delete handlers. Finally, same thing may happen in `HTMLEditor::OnEndHandlingTopLevelEditSubActionInternal`. This patch makes it check whether the top-level edit sub-action is a block level one or not and consider `BlockInlineCheck` with the result. Depends on D194180 Differential Revision: https://phabricator.services.mozilla.com/D194181 bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1865729 gecko-commit: edf9292c0bc9c671afa4de12648c16622e9d418c gecko-reviewers: m_kato
- Loading branch information