qwebirc.ui.HILIGHT_SPEECH = 2;
qwebirc.ui.HILIGHT_US = 3;
+qwebirc.ui.MAXIMUM_LINES_PER_WINDOW = 1000;
+
qwebirc.ui.WINDOW_LASTLINE = qwebirc.ui.WINDOW_QUERY | qwebirc.ui.WINDOW_MESSAGES | qwebirc.ui.WINDOW_CHANNEL | qwebirc.ui.WINDOW_STATUS;
qwebirc.ui.Window = new Class({
if(type)
line = this.parentObject.theme.message(type, line, lhilight);
- qwebirc.ui.Colourise(qwebirc.irc.IRCTimestamp(new Date()) + " " + line, element, this.client.exec, this.parentObject.urlDispatcher.bind(this.parentObject), this);
+ var tsE = document.createElement("span");
+ tsE.className = "timestamp";
+ tsE.appendChild(document.createTextNode(qwebirc.irc.IRCTimestamp(new Date()) + " "));
+ element.appendChild(tsE);
+
+ qwebirc.ui.Colourise(line, element, this.client.exec, this.parentObject.urlDispatcher.bind(this.parentObject), this);
this.scrollAdd(element);
},
errorMessage: function(message) {
if($defined(element)) {
var sd = this.scrolledDown();
parent.appendChild(element);
+ if(parent.childNodes.length > qwebirc.ui.MAXIMUM_LINES_PER_WINDOW)
+ parent.removeChild(parent.firstChild);
if(sd) {
if(this.scrolltimer)
$clear(this.scrolltimer);