diff options
author | Loren Burkholder <computersemiexpert@outlook.com> | 2022-04-19 23:18:11 -0400 |
---|---|---|
committer | Loren Burkholder <computersemiexpert@outlook.com> | 2022-06-29 22:02:20 -0400 |
commit | 169384f0fa41cc8a52428f27bc3042dc849dd8c9 (patch) | |
tree | 048b76aaeec2760c8edd403821a8cf61f542a729 /src/timeline/RoomlistModel.cpp | |
parent | Fix typoed variable name (diff) | |
download | nheko-169384f0fa41cc8a52428f27bc3042dc849dd8c9.tar.xz |
Add space notifications to room list
Diffstat (limited to 'src/timeline/RoomlistModel.cpp')
-rw-r--r-- | src/timeline/RoomlistModel.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/timeline/RoomlistModel.cpp b/src/timeline/RoomlistModel.cpp index 1cf16243..3b46c053 100644 --- a/src/timeline/RoomlistModel.cpp +++ b/src/timeline/RoomlistModel.cpp @@ -330,10 +330,13 @@ RoomlistModel::addRoom(const QString &room_id, bool suppressInsertNotification) Qt::DisplayRole, }); + if (getRoomById(room_id)->isSpace()) + return; // no need to update space notifications + int total_unread_msgs = 0; for (const auto &room : qAsConst(models)) { - if (!room.isNull()) + if (!room.isNull() && !room->isSpace()) total_unread_msgs += room->notificationCount(); } |