mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-11 05:51:51 +00:00
languages list: template used
This commit is contained in:
parent
ee8cc4cb7c
commit
538a74c56d
2 changed files with 7 additions and 4 deletions
|
|
@ -9,10 +9,9 @@ function on_open()
|
|||
table.sort(names)
|
||||
|
||||
local panel = document.root
|
||||
for _,k in ipairs(names) do
|
||||
panel:add(string.format(
|
||||
"<button onclick=%q>%s</button>",
|
||||
string.format("core.set_setting('ui.language', %q) menu:back()", invlocales[k]), k
|
||||
for _,name in ipairs(names) do
|
||||
panel:add(gui.template(
|
||||
"language", {id=invlocales[name], name=name}
|
||||
))
|
||||
end
|
||||
panel:add("<button onclick='menu:back()'>@Back</button>")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue