Skip to content

Conversation

rniwa
Copy link
Member

@rniwa rniwa commented Oct 10, 2022

aef26c6

[Live Range Selection] A few tests fail due to behavior difference in VisibleSelection::selectionFromContentsOfNode
https://bugs.webkit.org/show_bug.cgi?id=246284

Reviewed by Darin Adler.

Explicitly canonicalize selection start & end in VisibleSelection::selectionFromContentsOfNode so that
enabling live range selection wouldn't cause a new test failure.

Also add variants of the tests that enable live range selection.

* LayoutTests/editing/deleting/paste-with-transparent-background-color-live-range-expected.txt: Added.
* LayoutTests/editing/deleting/paste-with-transparent-background-color-live-range.html: Added.
* LayoutTests/editing/execCommand/delete-selection-has-style-live-range-expected.txt: Added.
* LayoutTests/editing/execCommand/delete-selection-has-style-live-range.html: Added.
* LayoutTests/editing/input/select-all-clear-input-method-live-range-expected.txt: Added.
* LayoutTests/editing/input/select-all-clear-input-method-live-range.html: Added.
* LayoutTests/editing/pasteboard/contenteditable-pre-2-live-range-expected.txt: Added.
* LayoutTests/editing/pasteboard/contenteditable-pre-2-live-range.html: Added.
* LayoutTests/editing/pasteboard/copy-paste-content-starting-and-ending-canvas-live-range-expected.txt: Added.
* LayoutTests/editing/pasteboard/copy-paste-content-starting-and-ending-canvas-live-range.html: Added.
* LayoutTests/editing/pasteboard/preserve-line-break-at-end-of-pasted-content-live-range-expected.txt: Added.
* LayoutTests/editing/pasteboard/preserve-line-break-at-end-of-pasted-content-live-range.html: Added.
* LayoutTests/editing/selection/select-all-user-select-none-live-range-expected.txt: Added.
* LayoutTests/editing/selection/select-all-user-select-none-live-range.html: Added.
* Source/WebCore/editing/VisibleSelection.cpp:
(WebCore::VisibleSelection::selectionFromContentsOfNode):

Canonical link: https://commits.webkit.org/255372@main

4fe3f87

Misc iOS, tvOS & watchOS macOS Linux Windows
✅ 🧪 style ✅ 🛠 ios ✅ 🛠 mac ✅ 🛠 wpe 🛠 🧪 win
✅ 🧪 bindings ✅ 🛠 ios-sim ✅ 🛠 mac-debug ✅ 🛠 gtk ✅ 🛠 wincairo
✅ 🧪 webkitperl ✅ 🧪 ios-wk2 ✅ 🛠 mac-AS-debug ✅ 🧪 gtk-wk2
✅ 🧪 api-ios ✅ 🧪 api-mac 🧪 api-gtk
✅ 🛠 tv 🧪 mac-wk1
✅ 🛠 tv-sim ✅ 🧪 mac-wk2
✅ 🛠 watch 🧪 mac-AS-debug-wk2
✅ 🛠 🧪 unsafe-merge ✅ 🛠 watch-sim ✅ 🧪 mac-wk2-stress

@rniwa rniwa self-assigned this Oct 10, 2022
@rniwa rniwa added HTML Editing For bugs in HTML editing support (including designMode and contentEditable). WebKit Nightly Build labels Oct 10, 2022
@rniwa rniwa requested review from darinadler and whsieh October 10, 2022 18:08
@rniwa rniwa added the unsafe-merge-queue Applied to send a pull request to merge-queue, but skip building and testing label Oct 11, 2022
… VisibleSelection::selectionFromContentsOfNode

https://bugs.webkit.org/show_bug.cgi?id=246284

Reviewed by Darin Adler.

Explicitly canonicalize selection start & end in VisibleSelection::selectionFromContentsOfNode so that
enabling live range selection wouldn't cause a new test failure.

Also add variants of the tests that enable live range selection.

* LayoutTests/editing/deleting/paste-with-transparent-background-color-live-range-expected.txt: Added.
* LayoutTests/editing/deleting/paste-with-transparent-background-color-live-range.html: Added.
* LayoutTests/editing/execCommand/delete-selection-has-style-live-range-expected.txt: Added.
* LayoutTests/editing/execCommand/delete-selection-has-style-live-range.html: Added.
* LayoutTests/editing/input/select-all-clear-input-method-live-range-expected.txt: Added.
* LayoutTests/editing/input/select-all-clear-input-method-live-range.html: Added.
* LayoutTests/editing/pasteboard/contenteditable-pre-2-live-range-expected.txt: Added.
* LayoutTests/editing/pasteboard/contenteditable-pre-2-live-range.html: Added.
* LayoutTests/editing/pasteboard/copy-paste-content-starting-and-ending-canvas-live-range-expected.txt: Added.
* LayoutTests/editing/pasteboard/copy-paste-content-starting-and-ending-canvas-live-range.html: Added.
* LayoutTests/editing/pasteboard/preserve-line-break-at-end-of-pasted-content-live-range-expected.txt: Added.
* LayoutTests/editing/pasteboard/preserve-line-break-at-end-of-pasted-content-live-range.html: Added.
* LayoutTests/editing/selection/select-all-user-select-none-live-range-expected.txt: Added.
* LayoutTests/editing/selection/select-all-user-select-none-live-range.html: Added.
* Source/WebCore/editing/VisibleSelection.cpp:
(WebCore::VisibleSelection::selectionFromContentsOfNode):

Canonical link: https://commits.webkit.org/255372@main
@webkit-commit-queue
Copy link
Collaborator

Committed 255372@main (aef26c6): https://commits.webkit.org/255372@main

Reviewed commits have been landed. Closing PR #5197 and removing active labels.

@webkit-early-warning-system webkit-early-warning-system merged commit aef26c6 into WebKit:main Oct 11, 2022
@webkit-commit-queue webkit-commit-queue removed the unsafe-merge-queue Applied to send a pull request to merge-queue, but skip building and testing label Oct 11, 2022
@rniwa rniwa deleted the fix246284 branch February 2, 2023 02:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
HTML Editing For bugs in HTML editing support (including designMode and contentEditable).
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants