Closed Bug 387849 Opened 13 years ago Closed 6 years ago

Remove the "Open Location..." menu item


(Firefox :: Menus, defect)

Not set



Firefox 29


(Reporter: testo.moz, Assigned: esajic)


(Blocks 1 open bug)


(Whiteboard: [good first bug][lang=xul][mentor=dao][good first verify])


(1 file)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a6) Gecko/20070629 GranParadiso/3.0a6
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a6) Gecko/20070629 GranParadiso/3.0a6

The "Open Location" menu item seams pointless to me if the url bar is showing.  I think this item should be hidden if the url bar is showing.  All it does is focus on it.  This can be done with less mouse clicks my just pointing at it.  It should be fairly simple to add a function to check this when the menu it opened.

The menu item does not have an ID so this is the best I can think of.

function  hideOpenLocation() {
var urlbar = document.getElementById('urlbar');
var openLocation = document.getElementById('Browser:OpenLocation');
if(!urlbar) {
} else {

Reproducible: Always
Ever confirmed: true
Summary: Open Location menu item seems pointless → Hide the "Open Location..." menu item if the location bar is shown
Version: unspecified → Trunk
I also think the option is confusing.  If the address bar is shown, the only action it has is to select and focus the address bar which is a very subtle action at best and no action at all if the address bar was already in that state when the menu option was selected.

I think either:

1. The option should be ghosted when the address bar is visible.
2. It should open a dialog for entering an address (like Internet Explorer).
3. It should be turned into a option on the view menu for toggling the address bar.

Also, an ellipsis on a menu is used to mean 'opens a new window or dialog' which this option does not, so that should be removed too.
Whiteboard: [triage]
Location bar will no longer be removable, so this is now just to remove the menu item.
Summary: Hide the "Open Location..." menu item if the location bar is shown → Hide the "Open Location..." menu item
Whiteboard: [triage]
So at this point this menu item only exposes the keyboard shortcut, but since we landed bug 896918, we can handle this just like bug 513165, bug 513168 and bug 519937...
Depends on: 896918
Whiteboard: [good first bug][lang=xul][mentor=dao]
Summary: Hide the "Open Location..." menu item → Remove the "Open Location..." menu item
Would it be OK if I have a go at making a patch for this one? For removing the "Open Location..." menu item altogether. Thanks!
See attached for my first attempt. I tested it by building it, running it and checking that the File menu didn't have Open Location... on it any more. Also I checked that the Command-L (Mac) keyboard shortcut still moves the focus to the Location bar.
I also ran the mochitest ./mach mochitest-browser browser/base/content/test/general/browser_popupUI.js which passed.
Feedback welcome. Cheers!
Attachment #8350692 - Flags: review?(dao)
Comment on attachment 8350692 [details] [diff] [review]

Looks good, thanks!
Attachment #8350692 - Flags: review?(dao) → review+
Assignee: nobody → esajic
Thanks :-)
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 29
No longer blocks: fxdesktopbacklog
Whiteboard: [good first bug][lang=xul][mentor=dao] → [good first bug][lang=xul][mentor=dao][good first verify]
Blocks: 1008793
No longer blocks: 1008793
Depends on: 1008793
You need to log in before you can comment on or make changes to this bug.