Skip to content

Commit

Permalink
setuichange: don't claer BTN watches
Browse files Browse the repository at this point in the history
after trying it seemed like it was not necessary.
  • Loading branch information
thyttan committed Jul 3, 2024
1 parent fb7bc5d commit eaa2918
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions apps/setuichange/boot.js
Original file line number Diff line number Diff line change
Expand Up @@ -103,11 +103,6 @@ Bangle.setUI = (function(mode, cb) {
Bangle.swipeHandler = options.swipe;
Bangle.on("swipe", Bangle.swipeHandler);
}
if (options.btn || options.btnRelease) {
// Make sure we only add the custom btn handlers. TODO: Deliberate on whether this is the right approach or not.
Bangle.btnWatches.forEach(clearWatch);
Bangle.btnWatches = [];
}
if (options.btn) Bangle.btnWatches.push(setWatch(options.btn.bind(options), BTN1, {repeat:1,edge:"rising"}))
if (options.btnRelease) Bangle.btnWatches.push(setWatch(options.btnRelease.bind(options), BTN1, {repeat:1,edge:"falling"}))
if (options.remove) // handler for removing the UI (intervals/etc)
Expand Down

0 comments on commit eaa2918

Please sign in to comment.