+ Label {
+ width: columnwidth * 0.15
+ text: overtook
+ color: delegate.highlighted ? Theme.highlightColor : Theme.primaryColor
+ horizontalAlignment: Text.AlignRight
+ }
+ Label {
+ width: columnwidth * 0.15
+ text: overtakenby
+ color: delegate.highlighted ? Theme.highlightColor : Theme.primaryColor
+ horizontalAlignment: Text.AlignRight
+ }
+ }
+ onClicked: pageStack.push(Qt.resolvedUrl("JourneyInfo.qml"), {title: "Journey info", index: index, start: journeymodel.epochToDateTime(start), duration: duration, overtook: overtook, overtakenby: overtakenby})
+
+ Component {
+ id: journeyMenuComponent
+ ContextMenu {
+ MenuItem {
+ text: qsTr("Edit")
+ onClicked: pageStack.push(Qt.resolvedUrl("JourneyEdit.qml"), {title: "Edit journey", index: index, start: journeymodel.epochToDateTime(start), duration: duration, overtook: overtook, overtakenby: overtakenby})
+ }
+ MenuItem {
+ text: qsTr("Delete")
+ onClicked: remove(index)
+ }
+ }
+ }
+
+ function remove(index) {
+ remorseAction(qsTr("Deleting journey"), function() {
+ onClicked: journeymodel.deleteJourney(index)
+ })