aboutsummaryrefslogtreecommitdiff
path: root/src/SetPointPage.qml
diff options
context:
space:
mode:
Diffstat (limited to 'src/SetPointPage.qml')
-rw-r--r--src/SetPointPage.qml9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/SetPointPage.qml b/src/SetPointPage.qml
index 50643b0..c2e8787 100644
--- a/src/SetPointPage.qml
+++ b/src/SetPointPage.qml
@@ -35,7 +35,7 @@ Item {
height: parent.width*0.2
//for the default text, we probably want a date/time
previewText: "Waypoint name"
- text: Date().toLocaleString(Locale.ShortFormat)
+ text: Date.toLocaleString(Locale.ShortFormat)
}
ListView {
id: iconSelectorView
@@ -89,8 +89,11 @@ Item {
}
function appendWayPoint() { //the colours.primary is currently a placeholder. it would be nice to let users select colours, but I CBA to write a colour picker right now.
- var newWayPointString = ">" + "selectedIcon" + ";" + coord + ";" + colours.primary + ";" + textBox.text + ";" + Date()
+ var newWayPointString = selectedIcon + ";" + coord.latitude + "," + coord.longitude + ";" + colours.primary + ";" + textBox.text + ";" + Date.now() + ">"
console.log(newWayPointString)
- pageStack.pop()
+ waypointList.value = waypointList.value + newWayPointString
+ setPointControls.visible = false
+ mapControls.visible = true
+ pageStack.pop(pageStack.currentLayer)
}
}