mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-11-22 19:08:58 +03:00
Fix room list updating on adding to hidden tag or removing tag
This commit is contained in:
parent
a2dab31fd6
commit
f35e826485
2 changed files with 4 additions and 0 deletions
|
@ -65,6 +65,7 @@ CommunitiesList::setCommunities(const mtx::responses::JoinedGroups &response)
|
||||||
addCommunity(group);
|
addCommunity(group);
|
||||||
|
|
||||||
communities_["world"]->setPressedState(true);
|
communities_["world"]->setPressedState(true);
|
||||||
|
selectedCommunity_ = "world";
|
||||||
emit communityChanged("world");
|
emit communityChanged("world");
|
||||||
sortEntries();
|
sortEntries();
|
||||||
}
|
}
|
||||||
|
@ -74,6 +75,7 @@ CommunitiesList::syncTags(const std::map<QString, RoomInfo> &info)
|
||||||
{
|
{
|
||||||
for (const auto &room : info)
|
for (const auto &room : info)
|
||||||
setTagsForRoom(room.first, room.second.tags);
|
setTagsForRoom(room.first, room.second.tags);
|
||||||
|
emit communityChanged(selectedCommunity_);
|
||||||
sortEntries();
|
sortEntries();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -231,6 +233,7 @@ CommunitiesList::highlightSelectedCommunity(const QString &community_id)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
selectedCommunity_ = community_id;
|
||||||
emit communityChanged(community_id);
|
emit communityChanged(community_id);
|
||||||
|
|
||||||
for (const auto &community : communities_) {
|
for (const auto &community : communities_) {
|
||||||
|
|
|
@ -53,6 +53,7 @@ private:
|
||||||
return communities_.find(id) != communities_.end();
|
return communities_.find(id) != communities_.end();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
QString selectedCommunity_;
|
||||||
QVBoxLayout *topLayout_;
|
QVBoxLayout *topLayout_;
|
||||||
QVBoxLayout *contentsLayout_;
|
QVBoxLayout *contentsLayout_;
|
||||||
QScrollArea *scrollArea_;
|
QScrollArea *scrollArea_;
|
||||||
|
|
Loading…
Reference in a new issue