Hide uninstall package button on unmodifiable paths (#8255)
This commit is contained in:
parent
17fcbff308
commit
f205d99aa7
|
@ -134,9 +134,13 @@ local function get_formspec(tabview, name, tabdata)
|
||||||
end
|
end
|
||||||
|
|
||||||
retval = retval .. "textarea[5.85,2.2;6.35,2.9;;" ..
|
retval = retval .. "textarea[5.85,2.2;6.35,2.9;;" ..
|
||||||
fgettext("Information:") .. ";" .. desc .. "]" ..
|
fgettext("Information:") .. ";" .. desc .. "]"
|
||||||
"button[5.5,4.65;3.25,1;btn_mod_mgr_delete_mod;" ..
|
|
||||||
fgettext("Uninstall Package") .. "]"
|
if core.may_modify_path(selected_pkg.path) then
|
||||||
|
retval = retval ..
|
||||||
|
"button[5.5,4.65;3.25,1;btn_mod_mgr_delete_mod;" ..
|
||||||
|
fgettext("Uninstall Package") .. "]"
|
||||||
|
end
|
||||||
end
|
end
|
||||||
return retval
|
return retval
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue