mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-03 12:35:58 +00:00
bug 397690: display full executable name instead of leaf name for applications in Applications prefpane; Patch by Jim Mathies, r=myk, a=mconnor
This commit is contained in:
parent
b838379102
commit
a370ce23c2
@ -1005,7 +1005,7 @@ var gApplicationsPane = {
|
||||
return this._prefsBundle.getString("saveFile");
|
||||
|
||||
case Ci.nsIHandlerInfo.useHelperApp:
|
||||
return aHandlerInfo.preferredApplicationHandler.name;
|
||||
return getDisplayNameForFile(aHandlerInfo.preferredApplicationHandler.executable);
|
||||
|
||||
case Ci.nsIHandlerInfo.handleInternally:
|
||||
// For the feed type, handleInternally means live bookmarks.
|
||||
@ -1065,7 +1065,7 @@ var gApplicationsPane = {
|
||||
isValidHandlerApp: function(aHandlerApp) {
|
||||
if (!aHandlerApp)
|
||||
return false;
|
||||
|
||||
|
||||
if (aHandlerApp instanceof Ci.nsILocalHandlerApp)
|
||||
return aHandlerApp.executable &&
|
||||
aHandlerApp.executable.exists() &&
|
||||
@ -1150,7 +1150,10 @@ var gApplicationsPane = {
|
||||
|
||||
let menuItem = document.createElementNS(kXULNS, "menuitem");
|
||||
menuItem.setAttribute("action", Ci.nsIHandlerInfo.useHelperApp);
|
||||
menuItem.setAttribute("label", possibleApp.name);
|
||||
if (possibleApp instanceof Ci.nsILocalHandlerApp)
|
||||
menuItem.setAttribute("label", getDisplayNameForFile(possibleApp.executable));
|
||||
else
|
||||
menuItem.setAttribute("label", possibleApp.name);
|
||||
menuItem.setAttribute("image", this._getIconURLForHandlerApp(possibleApp));
|
||||
|
||||
// Attach the handler app object to the menu item so we can use it
|
||||
|
Loading…
x
Reference in New Issue
Block a user