Allow accessing deviceName from qml
Summary: This allows it to be used outside of comboboxes in qml Reviewers: broulik Reviewed By: broulik Subscribers: broulik, kdeconnect Tags: #kde_connect Differential Revision: https://phabricator.kde.org/D16829
This commit is contained in:
parent
73191d8565
commit
e47fb17006
1 changed files with 1 additions and 0 deletions
|
@ -70,6 +70,7 @@ DevicesModel::DevicesModel(QObject* parent)
|
|||
QHash< int, QByteArray > DevicesModel::roleNames() const
|
||||
{
|
||||
QHash<int, QByteArray> names = QAbstractItemModel::roleNames();
|
||||
names.insert(NameModelRole, "deviceName");
|
||||
names.insert(IdModelRole, "deviceId");
|
||||
names.insert(IconNameRole, "iconName");
|
||||
names.insert(DeviceRole, "device");
|
||||
|
|
Loading…
Reference in a new issue