2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 14:38:15 +00:00

Extend pinned messages support.

Support them in saved messages and normal groups.
This commit is contained in:
John Preston
2018-10-31 15:29:14 +04:00
parent 6d65cf2382
commit 78da810114
12 changed files with 122 additions and 99 deletions

View File

@@ -121,12 +121,12 @@ DialogsInner::DialogsInner(QWidget *parent, not_null<Window::Controller*> contro
});
using UpdateFlag = Notify::PeerUpdate::Flag;
auto changes = UpdateFlag::PinnedChanged
auto changes = UpdateFlag::ChatPinnedChanged
| UpdateFlag::NameChanged
| UpdateFlag::PhotoChanged
| UpdateFlag::UserIsContact;
subscribe(Notify::PeerUpdated(), Notify::PeerUpdatedHandler(changes, [this](const Notify::PeerUpdate &update) {
if (update.flags & UpdateFlag::PinnedChanged) {
if (update.flags & UpdateFlag::ChatPinnedChanged) {
stopReorderPinned();
}
if (update.flags & UpdateFlag::NameChanged) {