Closed Bug 419725 Opened 16 years ago Closed 16 years ago

After hovering over autocomplete dropdown, right click in URL bar triggers new highlight

Categories

(Firefox :: Address Bar, defect, P2)

x86
Windows XP
defect

Tracking

()

VERIFIED FIXED

People

(Reporter: ria.klaassen, Assigned: enndeakin)

References

Details

(Keywords: regression)

Attachments

(1 file)

Steps to reproduce:

- Copy a word in a page that you want to do a keyword search for
- Click in the locationbar, leave your mouse under the locationbar and type the keyword + space
- Hovering over the autocomplete dropdown, right click behind the keyword

Result: the keyword gets blue, so if you choose "Paste" it replaces the keyword.
Expected result: should not select and replace the typed word.

Sorry for the bad summary, I have no inspiration for a better one.

Regression range is http://bonsai.mozilla.org/cvsquery.cgi?module=PhoenixTinderbox&date=explicit&mindate=1201128300&maxdate=1201133279
Flags: blocking-firefox3?
This is by design, I think. We changed the way focus works so that clicking in the location bar selects the entire contents as an optimization for the common path of "click, enter new URL."

An optimization which would help this use case (and some other copy/paste and switch-between-tabs) would be to *not* select the entire field contents after someone begins editing the field up until the point where they hit enter or ESC. We have code that watches for this "dirty" state (in order to draw/hide the Go button) so it should be possible.
Flags: wanted-firefox3+
Flags: blocking-firefox3?
Flags: blocking-firefox3-
Summary: Right click and paste in locationbar replaces already typed text → After hovering over autocomplete dropdown, right click triggers new highlight
Sorry for spam.
Summary: After hovering over autocomplete dropdown, right click triggers new highlight → After hovering over autocomplete dropdown, right click in URL bar triggers new highlight
(In reply to comment #1)
> This is by design, I think. We changed the way focus works so that clicking in
> the location bar selects the entire contents as an optimization for the common
> path of "click, enter new URL."

We didn't change that on Windows, and Ria's regression range implies an unexpected change caused by bug 407359.
Flags: blocking-firefox3- → blocking-firefox3?
Hmm, quite right, I totally misinterpreted Ria's STR, there.

This also seems related to bug 408723, no? Setting as P2 for now ...
Flags: blocking-firefox3? → blocking-firefox3+
Priority: -- → P2
-> Enn
Assignee: nobody → enndeakin
Also, I noticed while debugging that the contextmenu <handler> in autcomplete.xml doesn't do anything. The popup closes regardless. Maybe this could be removed as well?
Attachment #307740 - Flags: review?(mano)
Comment on attachment 307740 [details] [diff] [review]
fix by ignoring focus while calling focus() which prevents the clickSelectsAll behaviour from occuring

mano seems kinda busy atm.

r=me on this, if the contextmenu handler does nothing, it makes sense to remove the extra handler while you're in the neighbourhood.
Attachment #307740 - Flags: review?(mano) → review+
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9) Gecko/2008052906 Firefox/3.0

Ok, the steps are a bit hazy, but I couldn't recreate this problem in RC2. If you right-click behind the keyword, it does NOT select the keyword. So, when you paste, it does not replace the keyword. 
Marking as verified.
Status: RESOLVED → VERIFIED
Depends on: 445727
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: