qwebirc.ui.HILIGHT_SPEECH = 2;
qwebirc.ui.HILIGHT_US = 3;
+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({
Implements: [Events],
initialize: function(parentObject, client, type, name, identifier) {
this.lastSelected = null;
this.subWindow = null;
this.closed = false;
+
+ if(this.type & qwebirc.ui.WINDOW_LASTLINE) {
+ this.lastPositionLine = new Element("hr");
+ this.lastPositionLine.addClass("lastpos");
+ this.lastPositionLineInserted = false;
+ }
},
updateTopic: function(topic, element) {
qwebirc.ui.Colourise("[" + topic + "]", element, this.client.exec, this.parentObject.urlDispatcher.bind(this.parentObject), this);
this.subWindow = window;
},
select: function() {
+ if(this.lastPositionLineInserted && !this.parentObject.uiOptions.LASTPOS_LINE) {
+ this.lines.removeChild(this.lastPositionLine);
+ this.lastPositionLineInserted = false;
+ }
+
this.active = true;
this.parentObject.__setActiveWindow(this);
if(this.hilighted)
this.scrolltimer = null;
}
+ if(this.type & qwebirc.ui.WINDOW_LASTLINE) {
+ if(this.lastPositionLineInserted)
+ this.lines.removeChild(this.lastPositionLine);
+
+ if(this.parentObject.uiOptions.LASTPOS_LINE)
+ this.lines.appendChild(this.lastPositionLine);
+
+ this.lastPositionLineInserted = this.parentObject.uiOptions.LASTPOS_LINE;
+ }
+
this.active = false;
},
resetScrollPos: function() {
[4, "DEDICATED_NOTICE_WINDOW", "Send notices to dedicated message window", false],
[3, "NICK_OV_STATUS", "Show status (@/+) before nicknames in nicklist", true],
[5, "ACCEPT_SERVICE_INVITES", "Automatically join channels when invited by Q", true],
- [6, "USE_HIDDENHOST", "Hide your hostmask when authed to Q (+x)", true]
+ [6, "USE_HIDDENHOST", "Hide your hostmask when authed to Q (+x)", true],
+ [8, "LASTPOS_LINE", "Show a last position indicator for each window.", true]
];
qwebirc.config.DefaultOptions = null;