Hi all,

I'm using QML treeview 5.6, I have a QAbstractItemModel subclass model which is set to the model of the treeview.
The model has roles such as visible and name.

The tree view has a tableview column
Qt Code:
  1. TableViewColumn {
  2. title: "Name"
  3. role: "name"
  4. resizable: true
  5. }
To copy to clipboard, switch view to plain text mode 

And in the item delegate, I'm accessing the name as "model.name" and visible as "visible"
Delegate has a name and an icon field.

Qt Code:
  1. Text {
  2. id: label
  3. text: model.name
  4. font.family: "Open Sans"
  5. font.pixelSize: 13
  6. font.weight: Font.DemiBold
  7. elide: "ElideRight"
  8. anchors.verticalCenter: parent.verticalCenter
  9. width: parent.width - iconImage.width - 25
  10. }
  11. Image {
  12. id: iconImage
  13. height: 24
  14. anchors.right: parent.right
  15. anchors.rightMargin: 25
  16. fillMode: Image.PreserveAspectFit
  17. anchors.verticalCenter: parent.verticalCenter
  18. source: model.visible?"qrc:/icons/Visible.png": "qrc:/icons/Invisible.png"
  19. MouseArea {
  20. anchors.fill: parent
  21. hoverEnabled: true
  22. onClicked: {
  23. qmlApp.onTreeItemVisibleChanged(treeView.model.modelIndex(model.index), !model.visible)
  24. }
  25. }
  26. }
To copy to clipboard, switch view to plain text mode 

The reset of the property is happening in the C++ model, however it's not reflected in the QML file.

Kindly advice what i'm missing