зеркало из https://github.com/mozilla/gecko-dev.git
fix for #47830. thanks to gemal@gemal.dk for starting the fix.
rest of fix to #16336, hide "Get Next [x] News Message" menu item when not reading news. change [x] based on the server prefs. r=mscott
This commit is contained in:
Родитель
06908942d1
Коммит
847e6c3bc6
|
@ -666,9 +666,19 @@ function IsGetNextNMessagesEnabled()
|
||||||
var server = folder.server;
|
var server = folder.server;
|
||||||
var serverType = server.type;
|
var serverType = server.type;
|
||||||
|
|
||||||
if((serverType == "nntp"))
|
var menuItem = document.getElementById("menu_getnextnmsg");
|
||||||
|
if((serverType == "nntp")) {
|
||||||
|
var newsServer = server.QueryInterface(Components.interfaces.nsINntpIncomingServer);
|
||||||
|
var menuValue = Bundle.formatStringFromName("getNextNMessages",
|
||||||
|
[ newsServer.maxArticles], 1);
|
||||||
|
menuItem.setAttribute("value",menuValue);
|
||||||
|
menuItem.setAttribute("hidden","false");
|
||||||
return true;
|
return true;
|
||||||
else return false;
|
}
|
||||||
|
else {
|
||||||
|
menuItem.setAttribute("hidden","true");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function IsEmptyTrashEnabled()
|
function IsEmptyTrashEnabled()
|
||||||
|
|
|
@ -573,7 +573,7 @@ Rights Reserved.
|
||||||
accesskey="&getNewMsgCmd.accesskey;"
|
accesskey="&getNewMsgCmd.accesskey;"
|
||||||
key="key_getNewMessages"
|
key="key_getNewMessages"
|
||||||
observes="cmd_getNewMessages"/>
|
observes="cmd_getNewMessages"/>
|
||||||
<menuitem value="&getNextNMsgCmd.label;"
|
<menuitem id="menu_getnextnmsg" value="&getNextNMsgCmd.label;"
|
||||||
observes="cmd_getNextNMessages"/>
|
observes="cmd_getNextNMessages"/>
|
||||||
<menuitem value="&sendUnsentCmd.label;"
|
<menuitem value="&sendUnsentCmd.label;"
|
||||||
accesskey="&sendUnsentCmd.accesskey;"
|
accesskey="&sendUnsentCmd.accesskey;"
|
||||||
|
|
Загрузка…
Ссылка в новой задаче