-
- Downloads
Bug 1891659 - Make `AutoBlockElementsJoiner::DeleteTextAtStartAndEndOfRange()`...
Bug 1891659 - Make `AutoBlockElementsJoiner::DeleteTextAtStartAndEndOfRange()` handle the case when the range in a text node r=m_kato It assumes that the range is always starts and ends in different node. This is true for now, but this will be called with a text node to delete only preformatted line break. Note that the only caller of it does not need the text node(s) if it becomes empty. Therefore, this patch makes it remove the text node in such case. Note that the test changed in `input-events-get-target-ranges-deleting-in-list-items.tentative.html` was wrong and only Firefox passed it because the range description was `(#text "", 0) - (#text "", 10)` since the text nodes are removed after deleting the text data of them. Now, they become `(#text "list-item1", 0) - (#text "list-item2", 10)`. Depends on D207688 Differential Revision: https://phabricator.services.mozilla.com/D207689
Showing
- editor/libeditor/HTMLEditorDeleteHandler.cpp 93 additions, 31 deletionseditor/libeditor/HTMLEditorDeleteHandler.cpp
- testing/web-platform/tests/input-events/input-events-get-target-ranges-deleting-in-list-items.tentative.html 2 additions, 2 deletions...s-get-target-ranges-deleting-in-list-items.tentative.html
Loading
Please register or sign in to comment