mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-26 15:06:08 +03:00
Expose items' domain identifier in FileProviderMaterialisedItemsModel
Signed-off-by: Claudio Cambra <claudio.cambra@nextcloud.com>
This commit is contained in:
parent
0b961e9e17
commit
c763a9a227
2 changed files with 4 additions and 0 deletions
|
@ -44,6 +44,8 @@ QVariant FileProviderMaterialisedItemsModel::data(const QModelIndex &index, int
|
||||||
return item.identifier();
|
return item.identifier();
|
||||||
case ParentItemIdentifierRole:
|
case ParentItemIdentifierRole:
|
||||||
return item.parentItemIdentifier();
|
return item.parentItemIdentifier();
|
||||||
|
case DomainIdentifierRole:
|
||||||
|
return item.domainIdentifier();
|
||||||
case TypeIdentifierRole:
|
case TypeIdentifierRole:
|
||||||
return item.typeIdentifier();
|
return item.typeIdentifier();
|
||||||
case SymlinkTargetPathRole:
|
case SymlinkTargetPathRole:
|
||||||
|
@ -108,6 +110,7 @@ QHash<int, QByteArray> FileProviderMaterialisedItemsModel::roleNames() const
|
||||||
roleNames.insert({
|
roleNames.insert({
|
||||||
{ IdentifierRole, "identifier" },
|
{ IdentifierRole, "identifier" },
|
||||||
{ ParentItemIdentifierRole, "parentItemIdentifier" },
|
{ ParentItemIdentifierRole, "parentItemIdentifier" },
|
||||||
|
{ DomainIdentifierRole, "domainIdentifier" },
|
||||||
{ FilenameRole, "fileName" },
|
{ FilenameRole, "fileName" },
|
||||||
{ TypeIdentifierRole, "typeIdentifier" },
|
{ TypeIdentifierRole, "typeIdentifier" },
|
||||||
{ SymlinkTargetPathRole, "symlinkTargetPath" },
|
{ SymlinkTargetPathRole, "symlinkTargetPath" },
|
||||||
|
|
|
@ -32,6 +32,7 @@ public:
|
||||||
enum Roles {
|
enum Roles {
|
||||||
IdentifierRole = Qt::UserRole + 1,
|
IdentifierRole = Qt::UserRole + 1,
|
||||||
ParentItemIdentifierRole,
|
ParentItemIdentifierRole,
|
||||||
|
DomainIdentifierRole,
|
||||||
FilenameRole,
|
FilenameRole,
|
||||||
TypeIdentifierRole,
|
TypeIdentifierRole,
|
||||||
SymlinkTargetPathRole,
|
SymlinkTargetPathRole,
|
||||||
|
|
Loading…
Reference in a new issue