Hello,
I am having an issue with the button widget in my implementation for a long-press solution.
local buttonPressed local function startJobHandler(event) if (event.phase == "began") then buttonPressed = true timer.performWithDelay(2000, function() if (buttonPressed) then native.showAlert("Test", "Test test test test test.", {"Okay", "Retry"}) buttonPressed = false end end) elseif (event.phase == "ended" or event.phase == "cancelled") then buttonPressed = false end end
Once the alert is shown, the button becomes covered by the alert and the button fails to update the phase. Once the alert is closed, the button is stuck in the pressed state and requires an additional click (on the button or anywhere on the canvas) to update the state.
Is this something that I can handle on my end, or is this functionality working as intended?