Don't auto-focus new query windows
This commit is contained in:
parent
7d72f40d91
commit
dbeddccca6
@ -140,10 +140,14 @@ $(function() {
|
|||||||
channels: [data.chan]
|
channels: [data.chan]
|
||||||
})
|
})
|
||||||
);
|
);
|
||||||
sidebar.find(".chan")
|
var chan = sidebar.find(".chan")
|
||||||
.sort(function(a, b) { return $(a).data("id") - $(b).data("id"); })
|
.sort(function(a, b) { return $(a).data("id") - $(b).data("id"); })
|
||||||
.last()
|
.last();
|
||||||
.trigger("click");
|
if (!whois) {
|
||||||
|
chan = chan.filter(":not(.query)");
|
||||||
|
}
|
||||||
|
whois = false;
|
||||||
|
chan.click();
|
||||||
});
|
});
|
||||||
|
|
||||||
socket.on("msg", function(data) {
|
socket.on("msg", function(data) {
|
||||||
@ -389,11 +393,13 @@ $(function() {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
var whois = false;
|
||||||
chat.on("click", ".user", function() {
|
chat.on("click", ".user", function() {
|
||||||
var user = $(this).html().trim().replace(/[+%@~]/, "");
|
var user = $(this).html().trim().replace(/[+%@~]/, "");
|
||||||
if (user.indexOf("#") !== -1) {
|
if (user.indexOf("#") !== -1) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
whois = true;
|
||||||
var text = "/whois " + user;
|
var text = "/whois " + user;
|
||||||
socket.emit("input", {
|
socket.emit("input", {
|
||||||
target: chat.data("id"),
|
target: chat.data("id"),
|
||||||
|
Loading…
Reference in New Issue
Block a user