Bug 305360 - Add global default quit message preference.

ChatZilla only.
r=samuel
This commit is contained in:
silver%warwickcompsoc.co.uk 2005-08-22 18:40:36 +00:00
parent ab6ba04d26
commit 8349130cfb
3 changed files with 11 additions and 2 deletions

View File

@ -1416,6 +1416,8 @@ function cmdSSLServer(e)
function cmdQuit(e)
{
if ((typeof e.reason != "string") || !e.reason)
e.reason = client.prefs["defaultQuitMsg"];
if (!e.reason)
e.reason = client.userAgent;
@ -1431,7 +1433,9 @@ function cmdQuitMozilla(e)
function cmdDisconnect(e)
{
if (typeof e.reason != "string")
if ((typeof e.reason != "string") || !e.reason)
e.reason = client.prefs["defaultQuitMsg"];
if (!e.reason)
e.reason = client.userAgent;
e.network.quit(e.reason);
@ -1449,7 +1453,9 @@ function cmdDisconnectAll(e)
return;
}
if (typeof e.reason != "string")
if ((typeof e.reason != "string") || !e.reason)
e.reason = client.prefs["defaultQuitMsg"];
if (!e.reason)
e.reason = client.userAgent;
for (var i = 0; i < conNetworks.length; i++)

View File

@ -132,6 +132,7 @@ function initPrefs()
["dcc.listenPorts", [], "dcc.ports"],
["dcc.useServerIP", true, "dcc"],
["debugMode", "", "global"],
["defaultQuitMsg", "", "global"],
["desc", "New Now Know How", ".ident"],
["deleteOnPart", true, "global"],
["displayHeader", true, "appearance.misc"],

View File

@ -1176,6 +1176,8 @@ pref.dcc.useServerIP.label = Get local IP from server
pref.dcc.useServerIP.help = When turned on, ChatZilla will ask the server for your IP address when connecting. This allows DCC to obtain the correct IP address when operating behind a gateway or NAT-based system.
pref.debugMode.label = Debug mode
pref.debugMode.help = This preference is for debugging Chatzilla and can generate a lot of debug output (usually to the console). It is a list of letters, signifying what you want debug messages about. "c" for context menus (dumps data when opening a context menu), "d" for dispatch (dumps data when dispatching commands), and "t" for trace/hook (dumps data about hooks and the event queue processing) debugging.
pref.defaultQuitMsg.label = Default quit message
pref.defaultQuitMsg.help = Specifies a default quit message to use when one is not explicitly specified. Leave blank to use the basic ChatZilla one, which simply states what version you have.
pref.desc.label = Description
pref.desc.help = Sets the "description" (aka "real name") field shown in your /whois information. It is commonly used to include ones' real name, but you are not required to enter anything.
pref.deleteOnPart.label = Delete channel views on part