When autofilling, try to detect whether the user deleted text instead of checking whether the old search string starts with the new search string
Categories
(Firefox :: Address Bar, enhancement, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox68 | --- | fixed |
People
(Reporter: adw, Assigned: adw)
References
Details
Attachments
(1 file)
When a new search query starts, we disable autofill if the old search string starts with the new search string. That's because when the user deletes text at the end of the input, we don't want to autofill the same value that the user just deleted. Marco suggests we should do better and try to detect when the user has actually deleted text instead of, or instead of only, doing the string comparison.
I'll mark this as a P3 since it's not required for MVP imo, since the current behavior is what the legacy controller does. Also, I'm not sure it's even possible or a good idea to try and detect all the ways the user can delete text.
Updated•5 years ago
|
Updated•5 years ago
|
Updated•5 years ago
|
Updated•5 years ago
|
Updated•5 years ago
|
Assignee | ||
Comment 1•5 years ago
|
||
(In reply to Drew Willcoxon :adw from comment #0)
Also, I'm not sure it's even possible or a good idea to try
and detect all the ways the user can delete text.
I'm having success (so far) using nsIEditActionListener: https://searchfox.org/mozilla-central/rev/6dab6dad9cc852011a14275a8b2c2c03ed7600a7/editor/nsIEditActionListener.idl
Assignee | ||
Comment 2•5 years ago
|
||
A little hacky, see discussion in phabricator.
Assignee | ||
Comment 3•5 years ago
|
||
Assignee | ||
Comment 4•5 years ago
|
||
Pushed by dwillcoxon@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/47050699cd5c Use nsIEditActionListener to detect when the user deletes autofilled substrings. r=mak
Comment 6•5 years ago
|
||
bugherder |
Updated•5 years ago
|
Description
•