WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
213298
Insertion point is missing after focusing a text field that has been emptied
https://bugs.webkit.org/show_bug.cgi?id=213298
Summary
Insertion point is missing after focusing a text field that has been emptied
mitz
Reported
2020-06-17 09:04:42 PDT
To reproduce this bug: 1. In Safari, navigate to the URL 2. Press Delete to delete the contents of the text field 3. Press Tab to move focus away from the text field 4. Press Tab again to focus the text field Result: After step 2, the field is focused and empty with a blinking insertion point. After step 4, the field is focused and empty but the insertion point is missing.
Attachments
Add attachment
proposed patch, testcase, etc.
mitz
Comment 1
2020-06-17 09:07:27 PDT
Maybe focusing the empty field makes an empty selection in it (as normally focusing a field selects the entire contents) that is somehow different from a caret selection.
mitz
Comment 2
2020-06-17 09:09:43 PDT
Doesn’t happen if the text field never contained anything (the apparent difference being the presence or lack of a <br> in the shadow DOM).
Wenson Hsieh
Comment 3
2020-06-17 09:16:35 PDT
I'm able to repro. Some debug logging in FrameSelection::setSelectionWithoutUpdatingAppearance... After deleting: OLD: { OffsetInAnchor(<DIV 0x11dc9e2f0 id='' class=''>, 0) } NEW: { BeforeAnchor(<BR 0x11dc9f380 id='' class=''>) } After tabbing to the unified field: OLD: { BeforeAnchor(<BR 0x11dc9f380 id='' class=''>) } NEW: { None } After tabbing back to the text field: OLD: { None } NEW: { BeforeAnchor(<BR 0x11dc9f380 id='' class=''>), AfterAnchor(<BR 0x11dc9f380 id='' class=''>) }
Radar WebKit Bug Importer
Comment 4
2020-06-17 09:16:48 PDT
<
rdar://problem/64450787
>
Wenson Hsieh
Comment 5
2020-06-17 09:19:24 PDT
Also reproduces on stock Safari in macOS 10.15.6
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug