To reproduce: select several lines of (non-editable) text. Click and hold inside the selection, then begin dragging away. The selection shouldn’t change as you begin dragging, but it does.
What is this a regression from? I thought that I filed a bug about this several years ago (when it was a new regression), but I couldn't find it recently.
(In reply to comment #1) > What is this a regression from? I thought that I filed a bug about this > several years ago (when it was a new regression), but I couldn't find it > recently. I don’t know yet exactly when the regression happened. Currently, the bug doesn’t appear to happen in Legacy WebKit.
This is similar to bug 58406, and can be fixed in a similar manner.
Created attachment 242430 [details] Ignore mouse events received after starting a drag
Comment on attachment 242430 [details] Ignore mouse events received after starting a drag View in context: https://bugs.webkit.org/attachment.cgi?id=242430&action=review > Source/WebKit2/WebProcess/WebPage/WebPage.h:700 > + void willStartDrag() { m_isStartingDrag = true; } > + void didStartDrag() { m_isStartingDrag = false; } These don't nest, so there should be an assertion that willStartDrag() isn't called twice.
(In reply to comment #5) > Comment on attachment 242430 [details] > Ignore mouse events received after starting a drag > > View in context: > https://bugs.webkit.org/attachment.cgi?id=242430&action=review > > > Source/WebKit2/WebProcess/WebPage/WebPage.h:700 > > + void willStartDrag() { m_isStartingDrag = true; } > > + void didStartDrag() { m_isStartingDrag = false; } > > These don't nest, so there should be an assertion that willStartDrag() isn't > called twice. Added assertions and committed <http://trac.webkit.org/r176687>.
This commit introduced the following crashes: fast/events/clear-drag-state.html fast/css/user-drag-none.html editing/pasteboard/dataTransfer-setData-getData.html editing/pasteboard/drop-text-events-sideeffect-crash.html editing/pasteboard/drag-drop-iframe-refresh-crash.html editing/pasteboard/drop-text-events-sideeffect.html editing/selection/user-drag-element-and-user-select-none.html See: https://build.webkit.org/builders/Apple%20Mavericks%20Debug%20WK2%20%28Tests%29/builds/8311 https://build.webkit.org/results/Apple%20Mavericks%20Debug%20WK2%20(Tests)/r176693%20(8311)/results.html I verified this by locally building and running one of the tests. r176686 passes, r176687 crashes.
(In reply to comment #7) > This commit introduced the following crashes: > > fast/events/clear-drag-state.html > fast/css/user-drag-none.html > editing/pasteboard/dataTransfer-setData-getData.html > editing/pasteboard/drop-text-events-sideeffect-crash.html > editing/pasteboard/drag-drop-iframe-refresh-crash.html > editing/pasteboard/drop-text-events-sideeffect.html > editing/selection/user-drag-element-and-user-select-none.html > > See: > https://build.webkit.org/builders/ > Apple%20Mavericks%20Debug%20WK2%20%28Tests%29/builds/8311 > https://build.webkit.org/results/Apple%20Mavericks%20Debug%20WK2%20(Tests)/ > r176693%20(8311)/results.html > > I verified this by locally building and running one of the tests. r176686 > passes, r176687 crashes. Thank you. Note that those “crashes” are failures of one of the assertions added in the last moment.
(In reply to comment #7) > This commit introduced the following crashes: > > fast/events/clear-drag-state.html > fast/css/user-drag-none.html > editing/pasteboard/dataTransfer-setData-getData.html > editing/pasteboard/drop-text-events-sideeffect-crash.html > editing/pasteboard/drag-drop-iframe-refresh-crash.html > editing/pasteboard/drop-text-events-sideeffect.html > editing/selection/user-drag-element-and-user-select-none.html Created https://bugs.webkit.org/show_bug.cgi?id=139224 to track this issue. I also updated the TestExpectation in that bug.