diff --git a/apps.json b/apps.json index 23a5344e7..7576d584a 100644 --- a/apps.json +++ b/apps.json @@ -4676,11 +4676,11 @@ {"name":"pooqroman.json"} ] }, - { "id": "chargingStatus", + { "id": "widChargingStatus", "name": "Charging Status", - "shortName":"Charging", + "shortName":"ChargingStatus", "icon": "widget.png", - "version":"0.1.3", + "version":"0.1.4", "type": "widget", "description": "A simple widget that shows up whenever the watch starts charging.", "tags": "widget,battery", diff --git a/apps/chargingStatus/widget.js b/apps/chargingStatus/widget.js deleted file mode 100644 index 6a3837ace..000000000 --- a/apps/chargingStatus/widget.js +++ /dev/null @@ -1,23 +0,0 @@ -(() => { - Bangle.on('charging', (charging) => { - if (charging) { - Bangle.buzz(); - } - Bangle.drawWidgets(); // re-layout widgets - g.flip(); - }); - WIDGETS["chargingStatus"] = { - area: 'tr', - width: 32, - draw() { - g.reset(); - g.setColor("#FD0"); // on = amber - - //if (Bangle.isCharging()) { - g.drawImage(atob("GBiBAAAAAAAAAAAAAA//8B//+BgYGBgYGBgYGBgYGBgYGBgYGB//+B//+BgYGBgYGBgYGBgYGBgYGBgYGB//+A//8AAAAAAAAAAAAA=="), this.x, 2+this.y); - - //g.setColor('#0f0').drawImage(atob("EBCBAf9//3/+f/x//P/4//gH8A/wD+Af/x//P/4//n/+//7/"), this.x, this.y); - //} - }, - }; -})(); \ No newline at end of file diff --git a/apps/chargingStatus/ChangeLog b/apps/widChargingStatus/ChangeLog similarity index 100% rename from apps/chargingStatus/ChangeLog rename to apps/widChargingStatus/ChangeLog diff --git a/apps/widChargingStatus/widget.js b/apps/widChargingStatus/widget.js new file mode 100644 index 000000000..3c953ce17 --- /dev/null +++ b/apps/widChargingStatus/widget.js @@ -0,0 +1,38 @@ +(() => { + Bangle.on('charging', (charging) => { + if (charging) { + Bangle.buzz(); + } + Bangle.drawWidgets(); // re-layout widgets + g.flip(); + }); + + function draw() { + g.reset(); + g.setColor("#FD0"); // on = amber + //if (Bangle.isCharging()) { + g.drawImage(atob("GBiBAAAAAAAAAAAAAA//8B//+BgYGBgYGBgYGBgYGBgYGBgYGB//+B//+BgYGBgYGBgYGBgYGBgYGBgYGB//+A//8AAAAAAAAAAAAA=="), this.x, 2 + this.y); + //g.setColor('#0f0').drawImage(atob("EBCBAf9//3/+f/x//P/4//gH8A/wD+Af/x//P/4//n/+//7/"), this.x, this.y); + //} + } + + WIDGETS.chargingStatus = { + area: 'tr', + width: 32, + draw: draw, + }; + + function gpsDraw() { + g.reset(); + g.setColor("#FD0"); // on = amber + + g.drawImage(atob("GBiBAAAAAAAAAAAAAA//8B//+BgYGBgYGBgYGBgYGBgYGBgYGB//+B//+BgYGBgYGBgYGBgYGBgYGBgYGB//+A//8AAAAAAAAAAAAA=="), this.x, 2 + this.y); + + } + WIDGETS.gpsT = { + area: "tr", + width: 24, + draw: gpsDraw + }; + +})(); \ No newline at end of file diff --git a/apps/chargingStatus/widget.png b/apps/widChargingStatus/widget.png similarity index 100% rename from apps/chargingStatus/widget.png rename to apps/widChargingStatus/widget.png