mail/ui/options.lua
Athozus 720029a73e
Add settings (#85)
* Add settings

* Fix luacheck

* Fix unupdatable sorting fields values (settings)

* Better settings names

* Better sort settings behaviour

* Rework set_setting()

* Rework settings storage

* Better get sorting filters (inbox/outbox)

* Fix reseting/saving settings
2023-05-05 11:38:19 +02:00

14 lines
400 B
Lua

-- helper function for tabbed options
function mail.show_options(playername)
local index = mail.selected_idxs.optionstab[playername] or 1
if not mail.selected_idxs.optionstab[playername] then
mail.selected_idxs.optionstab[playername] = 1
end
if index == 1 then
mail.show_settings(playername)
elseif index == 2 then
mail.show_about(playername)
end
end