diff --git a/apps.json b/apps.json index 083a349ad..0c2a40144 100644 --- a/apps.json +++ b/apps.json @@ -942,12 +942,13 @@ { "id": "widlock", "name": "Lock Widget", - "version": "0.03", + "version": "0.04", "description": "On devices with always-on display (Bangle.js 2) this displays lock icon whenever the display is locked", "icon": "widget.png", "type": "widget", "tags": "widget,lock", "supports": ["BANGLEJS","BANGLEJS2"], + "sortorder": -1, "storage": [ {"name":"widlock.wid.js","url":"widget.js"} ] @@ -5618,7 +5619,7 @@ "shortName":"Simple Pedometer", "icon": "screenshot_widpa.png", "screenshots": [{"url":"screenshot_widpa.png"}], - "version":"0.01", + "version":"0.02", "type": "widget", "supports": ["BANGLEJS", "BANGLEJS2"], "readme": "README.md", @@ -5634,7 +5635,7 @@ "shortName":"Lato Pedometer", "icon": "screenshot_widpb.png", "screenshots": [{"url":"screenshot_widpb.png"}], - "version":"0.01", + "version":"0.02", "type": "widget", "supports": ["BANGLEJS", "BANGLEJS2"], "readme": "README.md", diff --git a/apps/widlock/ChangeLog b/apps/widlock/ChangeLog index 3b1436feb..8aeb75429 100644 --- a/apps/widlock/ChangeLog +++ b/apps/widlock/ChangeLog @@ -1,3 +1,4 @@ 0.01: First commit 0.02: Handle new firmwares with 'lock' event 0.03: Don't try to be fancy - just bail out on firmwares without a lock event +0.04: Set sortorder to -1 so that widget always takes up the furthest left position diff --git a/apps/widpa/ChangeLog b/apps/widpa/ChangeLog index 7b83706bf..5197bb4bd 100644 --- a/apps/widpa/ChangeLog +++ b/apps/widpa/ChangeLog @@ -1 +1,2 @@ 0.01: First release +0.02: Size widget after step count is reset diff --git a/apps/widpa/widpa.wid.js b/apps/widpa/widpa.wid.js index b8c439d2b..1c0f27394 100644 --- a/apps/widpa/widpa.wid.js +++ b/apps/widpa/widpa.wid.js @@ -6,7 +6,7 @@ WIDGETS["widpa"]={area:"tl",width:13,draw:function() { if (!Bangle.isLCDOn()) return; // dont redraw if LCD is off var steps = Bangle.getHealthStatus("day").steps; var w = 1 + (steps.toString().length)*12; - if (w > this.width) {this.width = w; setTimeout(() => Bangle.drawWidgets(),10); return;} + if (w != this.width) {this.width = w; setTimeout(() => Bangle.drawWidgets(),10); return;} g.reset(); g.setColor(g.theme.bg); g.fillRect(this.x, this.y, this.x + this.width, this.y + 23); diff --git a/apps/widpb/ChangeLog b/apps/widpb/ChangeLog index 7b83706bf..1409a81ff 100644 --- a/apps/widpb/ChangeLog +++ b/apps/widpb/ChangeLog @@ -1 +1,2 @@ 0.01: First release +0.02: Fixed widget id to wibpb, Size widget after step count is reset diff --git a/apps/widpb/widpb.wid.js b/apps/widpb/widpb.wid.js index d65d7fe43..6129fac51 100644 --- a/apps/widpb/widpb.wid.js +++ b/apps/widpb/widpb.wid.js @@ -1,13 +1,13 @@ // on.step version Bangle.on('step', function(s) { WIDGETS["bata"].draw(); }); Bangle.on('lcdPower', function(on) { - if (on) WIDGETS["bata"].draw(); + if (on) WIDGETS["widpb"].draw(); }); -WIDGETS["bata"]={area:"tl",width:13,draw:function() { +WIDGETS["widpb"]={area:"tl",width:13,draw:function() { if (!Bangle.isLCDOn()) return; // dont redraw if LCD is off var steps = Bangle.getHealthStatus("day").steps; var w = 1 + (steps.toString().length)*12; - if (w > this.width) {this.width = w; setTimeout(() => Bangle.drawWidgets(),10); return;} + if (w != this.width) {this.width = w; setTimeout(() => Bangle.drawWidgets(),10); return;} g.reset(); g.setColor(g.theme.bg); g.fillRect(this.x, this.y, this.x + this.width, this.y + 23); // erase background