mirror of https://github.com/espruino/BangleApps
attempt to use correct image for rendering
parent
c2b731a972
commit
67c72d337e
|
@ -4680,7 +4680,7 @@
|
|||
"name": "Charging Status",
|
||||
"shortName":"ChargingStatus",
|
||||
"icon": "widget.png",
|
||||
"version":"0.1.5",
|
||||
"version":"0.1.6",
|
||||
"type": "widget",
|
||||
"description": "A simple widget that shows up whenever the watch starts charging.",
|
||||
"tags": "widget,battery",
|
||||
|
|
|
@ -7,17 +7,25 @@
|
|||
g.flip();
|
||||
});
|
||||
|
||||
const chargingSymbol = {
|
||||
width: 16,
|
||||
height: 16,
|
||||
bpp: 1,
|
||||
transparent: 1,
|
||||
buffer: require("heatshrink").decompress(atob("/9/AIP+v/8AIP//ABBg/wh4BB8Ef/4BBn/+AIIXB/4BB"))
|
||||
};
|
||||
|
||||
function draw() {
|
||||
g.reset();
|
||||
g.setColor("#FD0"); // on = amber
|
||||
g.setColor("#FD0");
|
||||
//if (Bangle.isCharging()) {
|
||||
g.setColor('#0f0').drawImage(atob("EBCBAf9//3/+f/x//P/4//gH8A/wD+Af/x//P/4//n/+//7/"), this.x, this.y);
|
||||
g.drawImage(chargingSymbol, this.x + 2, this.y);
|
||||
//}
|
||||
}
|
||||
|
||||
WIDGETS.chargingStatus = {
|
||||
area: 'tr',
|
||||
width: 32,
|
||||
width: 20,
|
||||
draw: draw,
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue