Bug 1906110 Comment 0 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

Clicking on the urlbar to focus it, should normally Select All, so its contents are ready to be replaced.
Unfortunately often this doesn't work and I end up inserting some text in the middle of the URL.
I found this is due to a few (1px, 2px) mousemove between mousedown and mouseup, that I may inadvertently do.
This is normally not a problem, but because the URL shifts when we insert or remove icons before it, we end up causing a selection change (the mouse moved by 1 px, the url moved by many pixels, so now 1-3 characters are selected).

Other browsers solved this by not shifting the url between focused and unfocused state, though that means we can only have a fixed amount of space for icons before the url, we cannot dynamically insert or remove icons then.
Possible solutions to evaluate:
1. don't collapse/uncollapse icons on focus change if mousedown. We can probably do this with a `mousedown` attribute and changing a few css rules. Icons would instead appear/disappear on mouseup
2. we could ignore small mousemove (less than half of a character) when passing from focused to unfocused... this may potentially prevent some wanted selection change, or not catch larger mousemove that users with accessibility problems may do
Clicking on the urlbar to focus it, should normally Select All, so its contents are ready to be replaced.
Unfortunately often this doesn't work and I end up inserting some text in the middle of the URL.
I found this is due to a few (1px, 2px) mousemove between mousedown and mouseup, that I may inadvertently do.
This is normally not a problem, but because the URL shifts when we insert or remove icons before it, we end up causing a selection change (the mouse moved by 1 px, the url moved by many pixels, so now 1-3 characters are selected).

Other browsers solved this by not shifting the url between focused and unfocused state, though that means we can only have a fixed amount of space for icons before the url, we cannot dynamically insert or remove icons then.
Possible solutions to evaluate:
1. don't collapse/uncollapse icons on focus change if mousedown. We can probably do this with a `mousedown` attribute and changing a few `focusd` css rules. Icons would instead appear/disappear on mouseup
2. we could ignore small mousemove (less than half of a character) when passing from focused to unfocused... this may potentially prevent some wanted selection change, or not catch larger mousemove that users with accessibility problems may do
Clicking on the urlbar to focus it, should normally Select All, so its contents are ready to be replaced.
Unfortunately often this doesn't work and I end up inserting some text in the middle of the URL.
I found this is due to a few (1px, 2px) mousemove between mousedown and mouseup, that I may inadvertently do.
This is normally not a problem, but because the URL shifts when we insert or remove icons before it, we end up causing a selection change (the mouse moved by 1 px, the url moved by many pixels, so now 1-3 characters are selected).

Other browsers solved this by not shifting the url between focused and unfocused state, though that means we can only have a fixed amount of space for icons before the url, we cannot dynamically insert or remove icons then.
Possible solutions to evaluate:
1. don't collapse/uncollapse icons on focus change if mousedown. We can probably do this with a `mousedown` attribute and changing a few `focused` css rules. Icons would instead appear/disappear on mouseup
2. we could ignore small mousemove (less than half of a character) when passing from focused to unfocused... this may potentially prevent some wanted selection change, or not catch larger mousemove that users with accessibility problems may do

Back to Bug 1906110 Comment 0