Last commit also changed titles on Minetest dashboards to much more flexible [hypertext]
This commit is contained in:
parent
7ef0626357
commit
6c9353d389
@ -103,7 +103,7 @@ minetest.register_on_player_receive_fields(function (player, formname, fields)
|
||||
if org_name ~= "View..." then
|
||||
modpol.interactions.org_dashboard(
|
||||
pname, org_name)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end)
|
||||
@ -126,7 +126,7 @@ function modpol.interactions.org_dashboard(user, org_string)
|
||||
end
|
||||
return ""
|
||||
end
|
||||
|
||||
|
||||
-- identify parent
|
||||
local parent = modpol.orgs.get_org(org.parent)
|
||||
if parent then parent = parent.name
|
||||
@ -134,7 +134,7 @@ function modpol.interactions.org_dashboard(user, org_string)
|
||||
|
||||
-- prepare members menu
|
||||
local members = org.members
|
||||
|
||||
|
||||
-- prepare children menu
|
||||
local children = {}
|
||||
for k,v in ipairs(org.children) do
|
||||
@ -210,7 +210,7 @@ minetest.register_on_player_receive_fields(function (player, formname, fields)
|
||||
modpol.interactions.dashboard(pname)
|
||||
elseif fields.refresh then
|
||||
modpol.interactions.org_dashboard(pname, org.name)
|
||||
|
||||
|
||||
-- Put all dropdowns at the end
|
||||
-- Receiving modules
|
||||
elseif fields.members
|
||||
@ -245,7 +245,7 @@ minetest.register_on_player_receive_fields(function (player, formname, fields)
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
|
||||
-- Receiving pending
|
||||
elseif fields.pending
|
||||
and fields.pending ~= "View..." then
|
||||
@ -376,7 +376,7 @@ function modpol.interactions.display(
|
||||
end
|
||||
return
|
||||
end
|
||||
-- set up formspec
|
||||
-- set up formspec
|
||||
local formspec = {
|
||||
"formspec_version[4]",
|
||||
"size[10,8]",
|
||||
@ -409,7 +409,7 @@ function modpol.interactions.text_query(user, query, func)
|
||||
"formspec_version[4]",
|
||||
"size[10,4]",
|
||||
"label[0.5,1;", minetest.formspec_escape(query), "]",
|
||||
"field[0.5,1.25;9,0.8;input;;]",
|
||||
"field[0.5,1.25;9,0.8;input;;]",
|
||||
"button[0.5,2.5;1,0.8;yes;OK]",
|
||||
}
|
||||
local formspec_string = table.concat(formspec, "")
|
||||
@ -461,7 +461,7 @@ end
|
||||
-- receive fields
|
||||
minetest.register_on_player_receive_fields(function (player, formname, fields)
|
||||
if formname == "modpol:dropdown_query" then
|
||||
local pname = player:get_player_name()
|
||||
local pname = player:get_player_name()
|
||||
if fields.cancel then
|
||||
minetest.close_formspec(pname, formname)
|
||||
elseif fields.input == "View..." then
|
||||
|
Loading…
x
Reference in New Issue
Block a user