Use better id loading methodology
This commit is contained in:
parent
1ac4f3a97b
commit
350fc593ed
7 changed files with 20 additions and 8 deletions
|
|
@ -76,7 +76,7 @@ RoomlistModel::roleNames() const
|
|||
{IsSpace, "isSpace"},
|
||||
{Tags, "tags"},
|
||||
{ParentSpaces, "parentSpaces"},
|
||||
{RoomMemberCount, "roomMemberCount"},
|
||||
{IsDirect, "isDirect"},
|
||||
{DirectChatAvatarMxid, "directChatAvatarMxid"},
|
||||
};
|
||||
}
|
||||
|
|
@ -131,8 +131,8 @@ RoomlistModel::data(const QModelIndex &index, int role) const
|
|||
list.push_back(QString::fromStdString(t));
|
||||
return list;
|
||||
}
|
||||
case Roles::RoomMemberCount:
|
||||
return room->roomMemberCount();
|
||||
case Roles::IsDirect:
|
||||
return room->isDirect();
|
||||
case Roles::DirectChatAvatarMxid:
|
||||
return room->directChatAvatarMxid();
|
||||
default:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue