Update app.js

Update progress bar on Bangle1 button presses.
Clean up timer before exiting.
pull/1612/head
Andrew Gregory 2022-03-22 23:26:50 +08:00 committed by GitHub
parent 9886125fbd
commit 1d7c090c21
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions

View File

@ -369,11 +369,15 @@ function bangle1Btn(e) {
var dy = state.listy - E.clip(id * TOKEN_HEIGHT - half(AR.h - TOKEN_HEIGHT), 0, Math.max(0, tokens.length * TOKEN_HEIGHT - AR.h));
onDrag({b:1, dy:dy});
changeId(id);
drawProgressBar();
}
timerCalc();
}
function exitApp() {
if (state.drawtimer) {
clearTimeout(state.drawtimer);
}
Bangle.showLauncher();
}