client: Optionally ensure backlog on buffer show
authorShane Synan <digitalcircuit36939@gmail.com>
Sun, 28 Jun 2020 05:41:00 +0000 (01:41 -0400)
committerManuel Nickschas <sputnick@quassel-irc.org>
Sun, 4 Oct 2020 16:19:48 +0000 (18:19 +0200)
commit02966c1d1a668b2382de899008e6fefb42da4bbb
treefb5560fb362f4fdf8133b3084cb76001a7712803
parent00cc0dfd645cce97c120111f5e5fd4c02ed021c1
client: Optionally ensure backlog on buffer show

Add a default-enabled option to ensure backlog is available when
showing a buffer, using the same logic as scrolling up in a buffer
whenever switching to a buffer.  No additional messages will be
fetched if the scrollbar is already visible.

This makes using Quassel without any initial backlog fetching more
convenient, as you don't need to scroll upon clicking every buffer.

Note: if all loaded messages are filtered out, nothing will appear to
be visible on the first showing, and more backlog will be fetched the
next time the buffer is shown (or if scrolled, like before).  This
happens with Quassel today already, anyways, but implementing
"fetch until visible" be a good future improvement, mirroring what
Quasseldroid does.
src/client/backlogsettings.cpp
src/client/backlogsettings.h
src/qtui/bufferwidget.cpp
src/qtui/bufferwidget.h
src/qtui/chatview.cpp
src/qtui/chatview.h
src/qtui/settingspages/backlogsettingspage.ui