diff --git a/apps.json b/apps.json index 8e7c4202b..ac3911a71 100644 --- a/apps.json +++ b/apps.json @@ -11,7 +11,7 @@ "custom": "custom.html", "customConnect": true, "storage": [ - + ], "sortorder": -20 }, @@ -1297,7 +1297,7 @@ "supports": ["BANGLEJS"], "custom": "custom.html", "storage": [ - + ] }, { @@ -3452,7 +3452,7 @@ { "id": "simplest", "name": "Simplest Clock", - "version": "0.02", + "version": "0.03", "description": "The simplest working clock, acts as a tutorial piece", "icon": "simplest.png", "type": "clock", diff --git a/apps/simplest/ChangeLog b/apps/simplest/ChangeLog index d69da4ddc..f37015d6a 100644 --- a/apps/simplest/ChangeLog +++ b/apps/simplest/ChangeLog @@ -1,2 +1,3 @@ 0.01: Modified for use with new bootloader and firmware 0.02: Use Bangle.setUI for button/launcher handling +0.03: Fix display for Bangle 2 diff --git a/apps/simplest/app.js b/apps/simplest/app.js index 2ed4e5580..68564ff33 100644 --- a/apps/simplest/app.js +++ b/apps/simplest/app.js @@ -1,14 +1,17 @@ +const h = g.getHeight(); +const w = g.getWidth(); + function draw() { var d = new Date(); var da = d.toString().split(" "); var time = da[4].substr(0,5); g.reset(); - g.clearRect(0, 30, 239, 99); + g.clearRect(0, 30, w, 99); g.setFontAlign(0, -1); - g.setFont("Vector", 80); - g.drawString(time, 120, 40); + g.setFont("Vector", w/3); + g.drawString(time, w/2, 40); } // handle switch display on by pressing BTN1