widlockunlock: stop event propagation on tap

pull/3233/head
Rob Pilling 2024-03-03 22:38:04 +00:00
parent 4b38e2af42
commit 04057c4018
1 changed files with 2 additions and 0 deletions

View File

@ -11,6 +11,8 @@ Bangle.on('touch', (_btn, xy) => {
if(w.x - oversize <= x && x < w.x + 14 + oversize
&& w.y - oversize <= y && y < w.y + 24 + oversize)
{
E.stopEventPropagation && E.stopEventPropagation();
Bangle.setLocked(true);
const backlightTimeout = Bangle.getOptions().backlightTimeout; // ms