Only treat a single -j join as explicit
In other words, only automatically switch to an automatically joined channel window if there's only one. Otherwise, stay on the <network> window and avoid touching the channel windows with their automatic topic and names replies. This fixes unintentionally clearing saved window unread counts when rejoining channels automatically by switching to them as they are joined.weechat-hashes
parent
7807848bda
commit
180287164c
12
handle.c
12
handle.c
|
@ -239,14 +239,12 @@ static void handleReplyWelcome(struct Message *msg) {
|
||||||
set(&self.nick, msg->params[0]);
|
set(&self.nick, msg->params[0]);
|
||||||
completeTouch(Network, self.nick, Default);
|
completeTouch(Network, self.nick, Default);
|
||||||
if (self.join) {
|
if (self.join) {
|
||||||
uint count = 1;
|
|
||||||
for (const char *ch = self.join; *ch && *ch != ' '; ++ch) {
|
|
||||||
if (*ch == ',') count++;
|
|
||||||
}
|
|
||||||
ircFormat("JOIN %s\r\n", self.join);
|
ircFormat("JOIN %s\r\n", self.join);
|
||||||
replies[ReplyJoin] += count;
|
if (!strchr(self.join, ',')) {
|
||||||
replies[ReplyTopic] += count;
|
replies[ReplyJoin]++;
|
||||||
replies[ReplyNames] += count;
|
replies[ReplyTopic]++;
|
||||||
|
replies[ReplyNames]++;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue