add show_checkbox_dialog

This commit is contained in:
Evgeny
2021-08-28 09:18:39 +03:00
parent 5adc9e7d84
commit 6714963c60
4 changed files with 32 additions and 6 deletions

View File

@@ -0,0 +1,16 @@
function on_resume()
ui:show_text("Open dialog")
end
function on_click()
dialog_items = { "One", "Two", "Three" }
ui:show_radio_dialog("Title", dialog_items, 2)
end
function on_dialog_action(idx)
if idx == -1 then
ui:show_toast("Dialog cancelled")
else
ui:show_toast("Choosen: "..dialog_items[idx])
end
end