Files
aiolauncher_scripts/buttons_with_state_sample.lua
2021-08-01 19:57:41 +03:00

20 lines
306 B
Lua

buttons = { "Disabled", "Disabled", "Disabled" }
function on_resume()
redraw()
end
function on_click(idx)
if buttons[idx] == "Disabled" then
buttons[idx] = "Enabled"
else
buttons[idx] = "Disabled"
end
redraw()
end
function redraw()
ui:show_buttons(buttons)
end