Button press event?

Posted on
  • What event is called, when the button BTN1 is pressed (in a menu, e.g.).
    I want to use it as an alternative to tapping the "back" button.

  • I'm not quite sure I understand the question... And are you doing this on Bangle.js 1 or 2?

    You can use setWatch(function() { ....}, BTN) to call something when a button is pressed, which may help. But if you're actually in a menu (especially on new Bangle.js) then the best bet is to create your own Bangle.setUI function, detect if it's given a 'back' argument, and add your own handler - then it'll work for everything.

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview
About

Button press event?

Posted by Avatar for gfric @gfric

Actions