mirror of https://github.com/espruino/BangleApps
waypoints: Merge waypoint_editor into waypoints application
Waypoint editor is reasonably small piece of javascript, so merge it with waypoints and make it always-available.pull/3095/head
parent
726a81d54f
commit
afa7d801c3
|
@ -1,3 +0,0 @@
|
|||
0.01: New App!
|
||||
0.02: Display waypoint name instead of its index in remove menu and fix icon
|
||||
0.03: Use text input for waypoint names, allow marking waypoint with current GPS position
|
|
@ -1,3 +0,0 @@
|
|||
# Waypoints
|
||||
|
||||
Simple waypoint editor.
|
|
@ -1 +0,0 @@
|
|||
require("heatshrink").decompress(atob("mEwxH+AH4A/AA0QF1wABF94xrFwgvV63W5/PF1AsBAAQvBAAQviFggvHGRXWFwvWFigvKGQgPCFwwvMFxQvL54PDF9wuHF8wuIF7/OAYguFF7mBrtdFQWAvWA5+qvV6FxIvXrwfCGAQqBvXP0guLF6XV1awCmggCmgvB1Wk1QEBRpQvTJ4OAAgM6F4oAEFwulF66zBvXV62sMAM0M4IuKOYOlwGrF6nP0oXD54tGRpDLCO4TvXDwIAHXhB3BSQYvfdZPVSQIvsUILWBF8xeEX4OkF8wQFd7mlDgPP52q5wvDAYISF1elBAYvWwBNB54DBGYIAEO5YvSFAInB1asBQAQzBF5HQxGsF64rBvWlX4fO0nOSQgvD6E0TANeL65XCd4ySFCYWCe4ZhDF6GIxHQ6vVGgQAESQfOTwQvZnQWBmgXDF4qSC5+kGYOr62sR4U0R6WsI4eCF5AzETwYYBwWC6AvlX4gAIR553DR5Ivhd4OCFwYvpAAwv/F7wMBF6ouLF5APHF54sMF44SNF5IsPF4gUSGQQXVAH4A/AH4A/ADY"))
|
Binary file not shown.
Before Width: | Height: | Size: 11 KiB |
|
@ -1,15 +0,0 @@
|
|||
{ "id": "waypoint_editor",
|
||||
"name": "Waypoint editor",
|
||||
"version":"0.03",
|
||||
"description": "Allows editing waypoints on device",
|
||||
"icon": "app.png",
|
||||
"readme": "README.md",
|
||||
"supports" : ["BANGLEJS2"],
|
||||
"allow_emulator": true,
|
||||
"tags": "tool,outdoors,gps",
|
||||
"dependencies": {"textinput":"type"},
|
||||
"storage": [
|
||||
{"name":"waypoint_editor.app.js","url":"app.js"},
|
||||
{"name":"waypoint_editor.img","url":"app-icon.js","evaluate":true}
|
||||
]
|
||||
}
|
|
@ -1 +1,2 @@
|
|||
0.01: New App!
|
||||
0.02: Merge waypoint_editor here, so waypoints can be edited on device, too.
|
||||
|
|
|
@ -36,7 +36,9 @@ has the following contents:
|
|||
The file contains the initial NONE waypoint which is useful if you
|
||||
just want to display course and speed. The next two entries are
|
||||
waypoints to No 10 Downing Street and to Stone Henge - obtained from
|
||||
Google Maps. The last five entries are entries which can be *marked*.
|
||||
Google Maps. The last five entries are entries which can be
|
||||
*marked*. (Some applications support marking but do not support
|
||||
creating/naming a waypoint).
|
||||
|
||||
You add and delete entries using the Web IDE to load and then save
|
||||
the file from and to watch storage. The app itself does not limit the
|
||||
|
@ -44,7 +46,7 @@ number of entries although it does load the entire file into RAM
|
|||
which will obviously limit this.
|
||||
|
||||
|
||||
## Waypoint Editor
|
||||
## Editing waypoints over web interface
|
||||
|
||||
Clicking on the download icon of `Waypoints` in the app loader invokes the
|
||||
waypoint editor. The editor downloads and displays the current
|
||||
|
@ -54,3 +56,8 @@ edit boxes. It can be restored - by clicking the `Add waypoint`
|
|||
button. A new markable entry is created by using the `Add name`
|
||||
button. The edited `waypoints.json` file is uploaded to the Bangle by
|
||||
clicking the `Upload` button.
|
||||
|
||||
## Editing waypoints on the device
|
||||
|
||||
You can also edit waypoints on the device, just start the editor from
|
||||
the app launcher.
|
|
@ -1 +1 @@
|
|||
require("heatshrink").decompress(atob("mEwwJC/AH4A/AH4AgA=="))
|
||||
require("heatshrink").decompress(atob("mEwxH+AH4A/AA0QF1wABF94xrFwgvV63W5/PF1AsBAAQvBAAQviFggvHGRXWFwvWFigvKGQgPCFwwvMFxQvL54PDF9wuHF8wuIF7/OAYguFF7mBrtdFQWAvWA5+qvV6FxIvXrwfCGAQqBvXP0guLF6XV1awCmggCmgvB1Wk1QEBRpQvTJ4OAAgM6F4oAEFwulF66zBvXV62sMAM0M4IuKOYOlwGrF6nP0oXD54tGRpDLCO4TvXDwIAHXhB3BSQYvfdZPVSQIvsUILWBF8xeEX4OkF8wQFd7mlDgPP52q5wvDAYISF1elBAYvWwBNB54DBGYIAEO5YvSFAInB1asBQAQzBF5HQxGsF64rBvWlX4fO0nOSQgvD6E0TANeL65XCd4ySFCYWCe4ZhDF6GIxHQ6vVGgQAESQfOTwQvZnQWBmgXDF4qSC5+kGYOr62sR4U0R6WsI4eCF5AzETwYYBwWC6AvlX4gAIR553DR5Ivhd4OCFwYvpAAwv/F7wMBF6ouLF5APHF54sMF44SNF5IsPF4gUSGQQXVAH4A/AH4A/ADY"))
|
||||
|
|
|
@ -1,34 +0,0 @@
|
|||
// place your const, vars, functions or classes here
|
||||
|
||||
// clear the screen
|
||||
g.clear();
|
||||
|
||||
var n = 0;
|
||||
|
||||
// redraw the screen
|
||||
function draw() {
|
||||
g.reset().clearRect(Bangle.appRect);
|
||||
g.setFont("6x8").setFontAlign(0,0).drawString("Up / Down",g.getWidth()/2,g.getHeight()/2 - 20);
|
||||
g.setFont("Vector",60).setFontAlign(0,0).drawString(n,g.getWidth()/2,g.getHeight()/2 + 30);
|
||||
}
|
||||
|
||||
// Respond to user input
|
||||
Bangle.setUI({mode: "updown"}, function(dir) {
|
||||
if (dir<0) {
|
||||
n--;
|
||||
draw();
|
||||
} else if (dir>0) {
|
||||
n++;
|
||||
draw();
|
||||
} else {
|
||||
n = 0;
|
||||
draw();
|
||||
}
|
||||
});
|
||||
|
||||
// First draw...
|
||||
draw();
|
||||
|
||||
// Load widgets
|
||||
Bangle.loadWidgets();
|
||||
Bangle.drawWidgets();
|
|
@ -1,7 +1,7 @@
|
|||
{ "id": "waypoints",
|
||||
"name": "Waypoints",
|
||||
"version":"0.01",
|
||||
"description": "Provides 'waypoints.json' used by various navigation apps, as well as a way to edit it from the App Loader with maps or a list",
|
||||
"version":"0.02",
|
||||
"description": "Provides 'waypoints.json' used by various navigation apps, as well as a way to edit it from the App Loader or from the device",
|
||||
"icon": "app.png",
|
||||
"tags": "tool,outdoors,gps",
|
||||
"type": "waypoints",
|
||||
|
@ -9,6 +9,8 @@
|
|||
"readme": "README.md",
|
||||
"interface": "interface.html",
|
||||
"storage": [
|
||||
{"name":"waypoints.app.js","url":"waypoints.app.js"},
|
||||
{"name":"waypoints.img","url":"app-icon.js","evaluate":true},
|
||||
{"name":"waypoints","url":"lib.js"}
|
||||
],
|
||||
"data": [
|
||||
|
|
Loading…
Reference in New Issue