diff --git a/mozilla/suite/common/nsContextMenu.js b/mozilla/suite/common/nsContextMenu.js index eccd9b4a2eb..2a4b55d2c29 100644 --- a/mozilla/suite/common/nsContextMenu.js +++ b/mozilla/suite/common/nsContextMenu.js @@ -118,7 +118,12 @@ nsContextMenu.prototype = { var saveImageMenuItem = document.getElementById( 'context-saveimage' ); var imageName = extractFileNameFromUrl(this.imageURL); var bundle = srGetStrBundle("chrome://communicator/locale/contentAreaCommands.properties"); - var caption = bundle.formatStringFromName("saveImageAs",[imageName],1); + var caption; + if (imageName) { + caption = bundle.formatStringFromName("saveImageAs", [imageName], 1); + } else { + caption = bundle.GetStringFromName("saveImageAsNoFilename"); + } saveImageMenuItem.setAttribute( "label", caption ); } diff --git a/mozilla/suite/locales/en-US/chrome/common/contentAreaCommands.properties b/mozilla/suite/locales/en-US/chrome/common/contentAreaCommands.properties index 27fa00e224b..155251e853f 100644 --- a/mozilla/suite/locales/en-US/chrome/common/contentAreaCommands.properties +++ b/mozilla/suite/locales/en-US/chrome/common/contentAreaCommands.properties @@ -1,6 +1,7 @@ # context menu strings saveImageAs=Save Image (%S)... +saveImageAsNoFilename=Save Image... searchText=Search %S for "%S" SavePageTitle=Save Web Page