On switch-to-tab results, Alt+Enter should open the page in a new tab, and Ctrl+Enter should switch to tab as expected

VERIFIED FIXED in Firefox 4.0b2

Status

()

Firefox
Location Bar
VERIFIED FIXED
7 years ago
6 years ago

People

(Reporter: Elmar Ludwig, Assigned: adw)

Tracking

Trunk
Firefox 4.0b2
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [switch-to-tab])

Attachments

(1 attachment)

(Reporter)

Description

7 years ago
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.3a6pre) Gecko/20100611 Minefield/3.7a6pre

Some keyboard modifiers that trigger a page load (e.g. Ctrl+Enter) are broken on switch-to-tab entries in the autocomplete dropdown. Steps to reproduce:

1. open https://developer.mozilla.org/en/Build_Documentation in a tab
2. type "build" into location bar
3. navigate to "Build Instructions - MDC" switch-to-tab entry with keyboard
4. press Alt+Enter, Ctrl+Enter, Shift+Enter or Ctrl+Shift+Enter

Results:

Alt+Enter switches to the currently open tab instead of opening a new tab.

Ctrl+Enter tries to load "http://www.moz-action:switchtab,https:.com//developer.mozilla.org/en/Build_Documentation".

Shift+Enter and Ctrl+Shift+Enter behave similar to Ctrl+Enter.
(Reporter)

Updated

7 years ago
Summary: keyboard modifiers are broken on switch-to-tab entries → Alt+Enter and Ctrl+Enter are broken on switch-to-tab entries

Comment 1

7 years ago
duplicate of Bug 557650?
(Reporter)

Comment 2

7 years ago
(In reply to comment #1)
> duplicate of Bug 557650?

I no longer see bug 557650 in a current build (do you?), so I don't think this is the same issue.

Comment 3

7 years ago
alas i do

Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.3a6pre) Gecko/20100612 Minefield/3.7a6pre ( .NET CLR 3.5.30729)
(Assignee)

Comment 4

7 years ago
Created attachment 454654 [details] [diff] [review]
patch

Two fixes:

The Ctrl+Enter garbage URL is caused by trying to prepend "www" and append ".com" and so on before testing if the URL is a moz-action.  If the URL is a moz-action, we shouldn't do any of that.

Elmar suggests that Alt+Enter on a switch-to-tab result should instead open that page in a new tab, just as it does for normal results, and I agree.  So this patch checks if Alt was pressed, and if so, skips the switch-to-tab action.
Assignee: nobody → adw
Status: NEW → ASSIGNED
Attachment #454654 - Flags: review?(gavin.sharp)
Attachment #454654 - Flags: review?(gavin.sharp) → review+
(Assignee)

Updated

7 years ago
Summary: Alt+Enter and Ctrl+Enter are broken on switch-to-tab entries → On switch-to-tab results, Alt+Enter should open the page in a new tab, and Ctrl+Enter should switch to tab as expected
(Assignee)

Comment 5

7 years ago
http://hg.mozilla.org/mozilla-central/rev/574de87782f9
Status: ASSIGNED → RESOLVED
Last Resolved: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 4.0b2
When I try to open a duplicate tab in the same window, Alt+Enter does not work for me (Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:2.0b1) Gecko/20100630 Firefox/4.0b1).

IMO, a keyboard shortcut is helpful, but a visual cue would be helpful too. Maybe adding a context menu on right-click or somehow toggle the 'Switch to tab' with 'Open in new tab' onhover, etc.?
(Assignee)

Comment 7

7 years ago
Yes, this patch only landed last night, so it's not in beta 1, only last night's nightly and beta 2 when it's released.  I agree some visual cue would be nice.
Depends on: 581469
No longer depends on: 581469
Depends on: 595046
No longer depends on: 595046
Whiteboard: [switch-to-tab]
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.