From da9c60f4a20d36e06f0cbb9761e7758acee876f9 Mon Sep 17 00:00:00 2001 From: Martin Boonk Date: Fri, 14 Jul 2023 18:34:29 +0200 Subject: [PATCH 1/8] gpstrek - Remove unused osmand namespace --- apps/gpstrek/convert.xsl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/gpstrek/convert.xsl b/apps/gpstrek/convert.xsl index 7afbd6813..72b19b565 100644 --- a/apps/gpstrek/convert.xsl +++ b/apps/gpstrek/convert.xsl @@ -1,5 +1,5 @@ - + From 5a7fca1511bb5064703ac1ff358b4b482c13e395 Mon Sep 17 00:00:00 2001 From: Martin Boonk Date: Fri, 14 Jul 2023 18:34:51 +0200 Subject: [PATCH 2/8] gpstrek - Allow GPX 1.0 to be parsed --- apps/gpstrek/interface.html | 3 +++ 1 file changed, 3 insertions(+) diff --git a/apps/gpstrek/interface.html b/apps/gpstrek/interface.html index 1f6ed1f37..b645abb53 100644 --- a/apps/gpstrek/interface.html +++ b/apps/gpstrek/interface.html @@ -15,6 +15,9 @@ function handleOnload(readerEvent){ var content = readerEvent.target.result; + // Replace the gpx version 1.0 with 1.1 to allow parsing older gpx files. The nodes referenced by the xsl exist in both versions. + content = content.replaceAll("http://www.topografix.com/GPX/1/0", "http://www.topografix.com/GPX/1/1"); + var xsltProcessor = new XSLTProcessor(); var myXMLHTTPRequest = new XMLHttpRequest(); From 077156c559b1c540da12dd821288d396bedaec00 Mon Sep 17 00:00:00 2001 From: Rob Pilling Date: Fri, 14 Jul 2023 21:04:21 +0100 Subject: [PATCH 3/8] multitimer: fix hardmode in new alarms/timers --- apps/multitimer/app.js | 1 - 1 file changed, 1 deletion(-) diff --git a/apps/multitimer/app.js b/apps/multitimer/app.js index ae8647db0..677b971ef 100644 --- a/apps/multitimer/app.js +++ b/apps/multitimer/app.js @@ -265,7 +265,6 @@ function editTimer(idx, a) { a.last = 0; a.data.ot = a.timer; a.appid = "multitimer"; - a.js = "(require('Storage').read('multitimer.alarm.js') !== undefined) ? load('multitimer.alarm.js') : load('sched.js')"; if (idx < 0) alarms.push(a); else alarms[timerIdx[idx]] = a; require("sched").setAlarms(alarms); From 9b805d4692e69c7006ffa2bf80f86b77182cf784 Mon Sep 17 00:00:00 2001 From: Rob Pilling Date: Fri, 14 Jul 2023 21:29:58 +0100 Subject: [PATCH 4/8] multitimer: version bump --- apps/multitimer/ChangeLog | 1 + apps/multitimer/metadata.json | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/multitimer/ChangeLog b/apps/multitimer/ChangeLog index 842384c8d..27cfd17a5 100644 --- a/apps/multitimer/ChangeLog +++ b/apps/multitimer/ChangeLog @@ -2,3 +2,4 @@ 0.02: Update for time_utils module 0.03: Use default Bangle formatter for booleans 0.04: Remove copied sched alarm.js & import newer features (oneshot alarms) +0.05: Fix creating new alarms/timers in hardmode diff --git a/apps/multitimer/metadata.json b/apps/multitimer/metadata.json index 7a23052c9..1db3235a1 100644 --- a/apps/multitimer/metadata.json +++ b/apps/multitimer/metadata.json @@ -1,7 +1,7 @@ { "id": "multitimer", "name": "Multi Timer", - "version": "0.04", + "version": "0.05", "description": "Set timers and chronographs (stopwatches) and watch them count down in real time. Pause, create, edit, and delete timers and chronos, and add custom labels/messages. Also sets alarms.", "icon": "app.png", "screenshots": [ From 8d2616da5856ab7e50a7628d922b1f021ce60f75 Mon Sep 17 00:00:00 2001 From: Martin Boonk Date: Sun, 16 Jul 2023 10:45:22 +0200 Subject: [PATCH 5/8] keytimer - Use matching theme color for time display background --- apps/keytimer/ChangeLog | 3 ++- apps/keytimer/keypad.js | 3 ++- apps/keytimer/metadata.json | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/apps/keytimer/ChangeLog b/apps/keytimer/ChangeLog index 1c3954fc7..789ab85a8 100644 --- a/apps/keytimer/ChangeLog +++ b/apps/keytimer/ChangeLog @@ -1,3 +1,4 @@ 0.01: New app! 0.02: Submitted to the app loader -0.03: Rewrote to use scheduler library \ No newline at end of file +0.03: Rewrote to use scheduler library +0.04: Use correct background color for number display diff --git a/apps/keytimer/keypad.js b/apps/keytimer/keypad.js index 5844c9a63..6b34d19f2 100644 --- a/apps/keytimer/keypad.js +++ b/apps/keytimer/keypad.js @@ -95,7 +95,8 @@ function getFontSize(length) { function updateDisplay() { let displayString = inputStringToDisplayString(common.state.inputString); - g.clearRect(0, 24, 175, 43).setColor(storage.readJSON('setting.json').theme.fg2).setFontAlign(1, -1).setFont("Vector", getFontSize(displayString.length)).drawString(displayString, 176, 24); + let t = storage.readJSON('setting.json').theme; + g.setBgColor(t.bg2).clearRect(0, 24, 175, 43).setColor(t.fg2).setFontAlign(1, -1).setFont("Vector", getFontSize(displayString.length)).drawString(displayString, 176, 24); } exports.show = function (callerCommon) { diff --git a/apps/keytimer/metadata.json b/apps/keytimer/metadata.json index e0e46f92f..43edf9957 100644 --- a/apps/keytimer/metadata.json +++ b/apps/keytimer/metadata.json @@ -1,7 +1,7 @@ { "id": "keytimer", "name": "Keypad Timer", - "version": "0.03", + "version": "0.04", "description": "A timer with a keypad that runs in the background", "icon": "icon.png", "type": "app", From 2fb27c315a61676ddd49b1e3b0d3ca24f253c24f Mon Sep 17 00:00:00 2001 From: Martin Boonk Date: Sun, 16 Jul 2023 11:08:31 +0200 Subject: [PATCH 6/8] keytimer - Center icons on timer view buttons --- apps/keytimer/timerview.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/keytimer/timerview.js b/apps/keytimer/timerview.js index 4910d805f..e3c4de478 100644 --- a/apps/keytimer/timerview.js +++ b/apps/keytimer/timerview.js @@ -17,11 +17,11 @@ function drawButtons() { .drawLine(g.getWidth() / 2, BAR_TOP, g.getWidth() / 2, g.getHeight()) //Draw the buttons - .drawImage(BUTTON_ICONS.reset, g.getWidth() / 4, BAR_TOP); + .drawImage(BUTTON_ICONS.reset, g.getWidth() / 4, BAR_TOP + 12, {rotate:0}); // rotate option centers the image if (common.running()) { - g.drawImage(BUTTON_ICONS.pause, g.getWidth() * 3 / 4, BAR_TOP); + g.drawImage(BUTTON_ICONS.pause, g.getWidth() * 3 / 4, BAR_TOP + 12, {rotate:0}); } else { - g.drawImage(BUTTON_ICONS.play, g.getWidth() * 3 / 4, BAR_TOP); + g.drawImage(BUTTON_ICONS.play, g.getWidth() * 3 / 4, BAR_TOP + 12, {rotate:0}); } } From 903995ca70cf8c0c52db31beaa464ba73d87be88 Mon Sep 17 00:00:00 2001 From: Martin Boonk Date: Sun, 16 Jul 2023 11:29:29 +0200 Subject: [PATCH 7/8] keytimer - Use theme colors on timer display --- apps/keytimer/timerview.js | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/apps/keytimer/timerview.js b/apps/keytimer/timerview.js index e3c4de478..1b01fec6c 100644 --- a/apps/keytimer/timerview.js +++ b/apps/keytimer/timerview.js @@ -7,21 +7,25 @@ const BUTTON_ICONS = { let common; +let s = require("Storage").readJSON("setting.json"); + function drawButtons() { //Draw the backdrop const BAR_TOP = g.getHeight() - 24; - g.setColor(0, 0, 1).setFontAlign(0, -1) + g.setBgColor(s.theme.bg2).setColor(s.theme.fg2).setFontAlign(0, -1) .clearRect(0, BAR_TOP, g.getWidth(), g.getHeight()) - .fillRect(0, BAR_TOP, g.getWidth(), g.getHeight()) - .setColor(1, 1, 1) + .setColor(s.theme.fg2) .drawLine(g.getWidth() / 2, BAR_TOP, g.getWidth() / 2, g.getHeight()) //Draw the buttons + .setColor(s.theme.fg2) .drawImage(BUTTON_ICONS.reset, g.getWidth() / 4, BAR_TOP + 12, {rotate:0}); // rotate option centers the image if (common.running()) { - g.drawImage(BUTTON_ICONS.pause, g.getWidth() * 3 / 4, BAR_TOP + 12, {rotate:0}); + g.setColor(s.theme.fg2) + .drawImage(BUTTON_ICONS.pause, g.getWidth() * 3 / 4, BAR_TOP + 12, {rotate:0}); } else { - g.drawImage(BUTTON_ICONS.play, g.getWidth() * 3 / 4, BAR_TOP + 12, {rotate:0}); + g.setColor(s.theme.fg2) + .drawImage(BUTTON_ICONS.play, g.getWidth() * 3 / 4, BAR_TOP + 12, {rotate:0}); } } From 38f6ed54ff2bde3b51ab4d1529bd4b23bb97cd97 Mon Sep 17 00:00:00 2001 From: Martin Boonk Date: Sun, 16 Jul 2023 11:35:47 +0200 Subject: [PATCH 8/8] keytimer - Update changelog --- apps/keytimer/ChangeLog | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/keytimer/ChangeLog b/apps/keytimer/ChangeLog index 789ab85a8..d2481d44c 100644 --- a/apps/keytimer/ChangeLog +++ b/apps/keytimer/ChangeLog @@ -1,4 +1,4 @@ 0.01: New app! 0.02: Submitted to the app loader 0.03: Rewrote to use scheduler library -0.04: Use correct background color for number display +0.04: Use theme colors