Update app.js

master
Andy Smy 2025-04-18 21:06:57 +01:00 committed by GitHub
parent a84224e0d2
commit 3556edc969
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 9 additions and 6 deletions

View File

@ -97,8 +97,10 @@ function countDown(dir) {
Bangle.setUI({
mode : "custom",
swipe : (directionLR, directionUD)=>{
Bangle.setUI();
E.showMenu(menuItems);
if(!directionUD) {
Bangle.setUI();
startOver();
}
},
btn : ()=>{
// remove old button press handler
@ -128,10 +130,11 @@ function startOver(resume) {
Bangle.setUI({
mode : "custom",
swipe : (directionLR, directionUD)=>{
if (!directionUD) { // if tapped or button pressed, start/stop
countDown(1);
} else { // otherwise if dir nonzero, up/down
countDown(-1);
if (!directionUD) {
Bangle.setUI();
E.showMenu(menuItems);
} else {
countDown(-directionUD);
}
},
btn : ()=>{