Commit e8422196 authored by Nico Vertriest's avatar Nico Vertriest
Browse files

Doc: Update source code for deleting alarms


Rewrote delete statement in AlarmDelegate.qml

Change-Id: Ib112103c0666a6bce34576da5f38594ceac14788
Reviewed-by: default avatarMitch Curtis <mitch.curtis@qt.io>
Showing with 2 additions and 2 deletions
...@@ -136,7 +136,7 @@ ItemDelegate { ...@@ -136,7 +136,7 @@ ItemDelegate {
width: 40 width: 40
height: 40 height: 40
visible: root.checked visible: root.checked
onClicked: alarmModel.remove(alarmListView.currentIndex, 1) onClicked: root.ListView.view.model.remove(root.ListView.view.currentIndex, 1)
} }
} }
} }
...@@ -64,7 +64,7 @@ ApplicationWindow { ...@@ -64,7 +64,7 @@ ApplicationWindow {
ListView { ListView {
id: alarmListView id: alarmListView
anchors.fill: parent anchors.fill: parent
model: AlarmModel { id: alarmModel } model: AlarmModel {}
delegate: AlarmDelegate {} delegate: AlarmDelegate {}
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment