mirror of https://github.com/espruino/BangleApps
Bug fix screen backlight flashing
parent
5426519246
commit
e0adbd3c62
|
@ -91,13 +91,9 @@ function drawBlackBox() {
|
|||
function draw(){
|
||||
let time = 60000;
|
||||
if(charching){
|
||||
Bangle.setLCDTimeout(0);
|
||||
Bangle.setLCDPower(1);
|
||||
drawCharging();
|
||||
time = 500;
|
||||
}else{
|
||||
Bangle.setLCDTimeout(1);
|
||||
Bangle.setLCDPower(1);
|
||||
drawWatchface();
|
||||
}
|
||||
//console.log(charching);
|
||||
|
@ -296,6 +292,8 @@ Bangle.on('lcdPower',function(on) {
|
|||
});
|
||||
|
||||
Bangle.on('charging', function(charging) {
|
||||
Bangle.setLCDTimeout(!charging);
|
||||
Bangle.setLCDPower(1);
|
||||
charching = charging;
|
||||
draw();
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue