Refresh the notification count when unread stats change

libquotient doesn't update the notification count properly, so let's
listen on the unread stats changing instead.
This commit is contained in:
Joshua Goins
2023-02-22 10:38:47 -05:00
committed by Tobias Fella
parent b8e8fa3ee5
commit dae2cbab90

View File

@@ -200,7 +200,11 @@ void RoomListModel::connectRoomSignals(NeoChatRoom *room)
}
Q_EMIT newHighlight(room->id(), lastEvent->id(), room->displayName(), sender->displayname(), room->eventToString(*lastEvent), room->avatar(128));
});
#ifndef QUOTIENT_07
connect(room, &Room::notificationCountChanged, this, &RoomListModel::refreshNotificationCount);
#else
connect(room, &Room::unreadStatsChanged, this, &RoomListModel::refreshNotificationCount);
#endif
}
#ifndef QUOTIENT_07