-
Notifications
You must be signed in to change notification settings - Fork 681
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Reset the unread marker on channel change #527
Conversation
1db58cc
to
4d7dfdf
Compare
This restores the old behavior of resetting the unread marker on channel change, as that's usually at this point one wants to check for new messages and is also what matches on the server. I feel this is overall more consistent and useful, and also more in line with what other clients do.
4d7dfdf
to
1f11293
Compare
.find(".chan.active") | ||
.removeClass("active"); | ||
|
||
lastActiveChan | ||
.find(".unread-marker") | ||
.appendTo(lastActiveChan.find(".messages")); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't this work just fine?
lastActive
.find(".chan.active")
.removeClass("active")
.find(".unread-marker")
.appendTo(lastActiveChan.find(".messages"));
(I haven't tried, of course 😅)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, because the active window contains all the channels, so we need to find the specific channel. That was my initial solution before I ended up with a million unread markers in ever channels.
@maxpoulin64, I get your fix, but by any chance did you find out where this bug was introduced? I mean, at some point it was working, and then it was not anymore. I'd like to find the exact piece of code that broke it, for completeness. |
That would be 26bf948 And wow, I really pushed that fix? Damn, I really was tired that week. I thought it was that way by design at first with the new style. Well, either way, fixed :S |
👍 and merging. |
Reset the unread marker on channel change
This restores the old behavior of resetting the unread marker on channel change, as that's usually at this point one wants to check for new messages and is also what matches on the server. I feel this is overall more consistent and useful, and also more in line with what other clients do.