Unsaved preferences alert and save button show logic

This commit is contained in:
emanuele-f 2016-11-04 01:19:52 +01:00
parent 5c0e312782
commit dd1d943359
5 changed files with 235 additions and 20 deletions

View file

@ -32,7 +32,7 @@ function inline_input_form(name, placeholder, tooltip, value, can_edit, input_op
if(can_edit) then
print('<input title="'..tooltip..'" '..(input_opts or "")..' class="form-control '..(input_clss or "")..'" name="'..name..'" placeholder="'..placeholder..'" value="')
if(value ~= nil) then print(value) end
print[["></input>&nbsp;<button type="submit" style="position: absolute; margin-top: 0; height: 26px" class="btn btn-default btn-xs">Save</button>\n]]
print[["></input>&nbsp;<button type="submit" style="position: absolute; margin-top: 0; height: 26px" class="btn btn-default btn-xs">Save</button>]]
else
if(value ~= nil) then print(value) end
end