Bug 90159

Summary: user-select: none cursor turns to I-beam on mouse dragging
Product: WebKit Reporter: Yves Van Goethem <yves.vangoethem>
Component: UI EventsAssignee: Nobody <webkit-unassigned>
Status: RESOLVED INVALID    
Severity: Normal CC: ap, commit-queue, darin, enrica, mitz, rniwa, vani.hegde, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
URL: http://yves.vg/testcases/chrome/user_select_none_dragging.html
Attachments:
Description Flags
Patch
none
Patch none

Yves Van Goethem
Reported 2012-06-28 04:11:59 PDT
Observation: When you start selecting an area that has user-select:none; and drag the cursor around, it changes to a text cursor. Expected: The cursor should be default as defined.
Attachments
Patch (6.46 KB, patch)
2013-09-24 22:07 PDT, Vani Hegde
no flags
Patch (6.58 KB, patch)
2013-09-25 20:43 PDT, Vani Hegde
no flags
Vani Hegde
Comment 1 2013-09-24 22:07:25 PDT
Vani Hegde
Comment 2 2013-09-24 22:13:36 PDT
This has got nothing to do with user-select:none. The bug here is cursor type being changed to text cursor(I-Beam cursor) during selection, even when the cursor type is explicitly set to be something else. This is committed in blink https://codereview.chromium.org/23461040/
Ryosuke Niwa
Comment 3 2013-09-25 10:41:42 PDT
It seems like this is done intentionally. I'm not sure changing this behavior is desirable.
Ryosuke Niwa
Comment 4 2013-09-25 10:49:09 PDT
Hm... looking more closely, maybe this is a regression from http://trac.webkit.org/changeset/11490.
Ryosuke Niwa
Comment 5 2013-09-25 10:53:35 PDT
Comment on attachment 212536 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=212536&action=review > Source/WebCore/page/EventHandler.cpp:1371 > + // During selection, use an I-beam no matter what we're over. We should probably rephrase this comment to something along the line of "use an I-beam regardless of the content beneath the cursor when cursor is not explicitly specified." since now we're respecting cursor CSS property during text selection.
Ryosuke Niwa
Comment 6 2013-09-25 10:56:03 PDT
Comment on attachment 212536 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=212536&action=review > LayoutTests/editing/caret/selection-with-caret-type-progress.html:10 > + description('Tests whether explicitly set caret style is retained on performing text selection'); The description can be outside of this if. It would be nice if you had something like debug("This test requires eventSender") in the else clause. Better yet, explain how to manually test it.
Radar WebKit Bug Importer
Comment 7 2013-09-25 11:17:09 PDT
Vani Hegde
Comment 8 2013-09-25 20:14:06 PDT
(In reply to comment #5) > (From update of attachment 212536 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=212536&action=review > > > Source/WebCore/page/EventHandler.cpp:1371 > > + // During selection, use an I-beam no matter what we're over. > > We should probably rephrase this comment to something along the line of "use an I-beam regardless of the content beneath the cursor when cursor is not explicitly specified." > since now we're respecting cursor CSS property during text selection. Will do.
Vani Hegde
Comment 9 2013-09-25 20:43:39 PDT
Vani Hegde
Comment 10 2013-09-25 20:44:33 PDT
Uploaded patch with review comments incorporated.
WebKit Commit Bot
Comment 11 2013-09-30 00:11:29 PDT
Comment on attachment 212658 [details] Patch Clearing flags on attachment: 212658 Committed r156635: <http://trac.webkit.org/changeset/156635>
WebKit Commit Bot
Comment 12 2013-09-30 00:11:33 PDT
All reviewed patches have been landed. Closing bug.
mitz
Comment 13 2014-01-17 15:34:46 PST
(In reply to comment #11) > (From update of attachment 212658 [details]) > Clearing flags on attachment: 212658 > > Committed r156635: <http://trac.webkit.org/changeset/156635> This caused bug 127197.
Ryosuke Niwa
Comment 14 2014-04-22 16:02:36 PDT
(In reply to comment #13) > (In reply to comment #11) > > (From update of attachment 212658 [details] [details]) > > Clearing flags on attachment: 212658 > > > > Committed r156635: <http://trac.webkit.org/changeset/156635> > > This caused bug 127197. As I suspect, the old behavior was indeed intended. Revering the patch.
Ryosuke Niwa
Comment 15 2014-04-22 16:06:29 PDT
Note You need to log in before you can comment on or make changes to this bug.