Don't use "(null)" for the image filename if there is no filename in the
url. Bug 121504, r=doron, sr=blake git-svn-id: svn://10.0.0.236/trunk@113372 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
75cff9aa43
commit
ec37d8f825
@ -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 );
|
||||
}
|
||||
|
||||
@ -1,6 +1,7 @@
|
||||
# context menu strings
|
||||
|
||||
saveImageAs=Save Image (%S)...
|
||||
saveImageAsNoFilename=Save Image...
|
||||
searchText=Search %S for "%S"
|
||||
|
||||
SavePageTitle=Save Web Page
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user