Commit f0722277 authored by Volker Krause's avatar Volker Krause

Properly handle journey section begins/ends when setting platform names

This is still not perfect though, as we also need to consider adjacent
sections on layovers as well.
parent 74e54bc8
......@@ -146,12 +146,19 @@ Item {
Layout.alignment: Qt.AlignVCenter
visible: stop.stopPoint.hasCoordinate
icon.name: "map-symbolic"
onClicked: applicationWindow().pageStack.push(indoorMapPage, {
coordinate: Qt.point(stop.stopPoint.longitude, stop.stopPoint.latitude),
placeName: stop.stopPoint.name,
arrivalPlatformName: stop.hasExpectedPlatform ? stop.expectedPlatform : stop.scheduledPlatform,
departurePlatformName: stop.hasExpectedPlatform ? stop.expectedPlatform : stop.scheduledPlatform
})
onClicked: {
var args = {
coordinate: Qt.point(stop.stopPoint.longitude, stop.stopPoint.latitude),
placeName: stop.stopPoint.name
};
if (!isDeparture) {
args.arrivalPlatformName = stop.hasExpectedPlatform ? stop.expectedPlatform : stop.scheduledPlatform;
}
if (!isArrival) {
args.departurePlatformName = stop.hasExpectedPlatform ? stop.expectedPlatform : stop.scheduledPlatform;
}
applicationWindow().pageStack.push(indoorMapPage, args);
}
}
}
}
Markdown is supported
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