Bug 329038 - Don't use prefs from library code.

ChatZilla only.
r=silver
p=rdmsoft@bugs.rdmsoft.com (Robert Marshall)


git-svn-id: svn://10.0.0.236/trunk@191782 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
silver%warwickcompsoc.co.uk 2006-03-04 21:49:04 +00:00
parent 1eba868c47
commit 3ad04e4de1
4 changed files with 9 additions and 2 deletions

View File

@ -90,6 +90,7 @@ function CIRCDCC(parent)
}
CIRCDCC.prototype.TYPE = "IRCDCC";
CIRCDCC.prototype.listenPorts = [];
CIRCDCC.prototype.addUser =
function dcc_adduser(user, remoteIP)
@ -200,7 +201,7 @@ function dcc_getmatches(nickname, filename, types, dirs, states)
CIRCDCC.prototype.getNextPort =
function dcc_getnextport()
{
var portList = this.parent.prefs["dcc.listenPorts"];
var portList = this.listenPorts;
var newPort = this._lastPort;

View File

@ -2462,7 +2462,7 @@ function serv_cact (e)
CIRCServer.prototype.onCTCPFinger =
function serv_cfinger (e)
{
e.user.ctcp("FINGER", this.parent.prefs["desc"], "NOTICE");
e.user.ctcp("FINGER", this.parent.INITIAL_DESC, "NOTICE");
return true;
}

View File

@ -54,6 +54,7 @@ function CIRCServer() {}
function CIRCChannel() {}
function CIRCChanUser() {}
function CIRCUser() {}
function CIRCDCC() {}
function CIRCDCCUser() {}
function CIRCDCCChat() {}
function CIRCDCCFileTransfer() {}

View File

@ -263,6 +263,7 @@ function initPrefs()
var dccUserMaxLines = client.prefs["dccUserMaxLines"];
CIRCDCCChat.prototype.MAX_MESSAGES = dccUserMaxLines;
CIRCDCCFileTransfer.prototype.MAX_MESSAGES = dccUserMaxLines;
CIRCDCC.prototype.listenPorts = client.prefs["dcc.listenPorts"];
client.MAX_MESSAGES = client.prefs["clientMaxLines"];
client.charset = client.prefs["charset"];
@ -659,6 +660,10 @@ function onPrefChanged(prefName, newValue, oldValue)
CIRCNetwork.prototype.MAX_CONNECT_ATTEMPTS = newValue;
break;
case "dcc.listenPorts":
CIRCDCC.prototype.listenPorts = newValue;
break;
case "dccUserMaxLines":
CIRCDCCFileTransfer.prototype.MAX_MESSAGES = newValue;
CIRCDCCChat.prototype.MAX_MESSAGES = newValue;