Commit cc2290e8 authored by Marie Claire Lagier's avatar Marie Claire Lagier
Browse files

par26menu deleted

parent 38d0c246
Pipeline #21771 failed
#from bliss import setup_globals
from bliss.config import static
from bliss.shell.cli.user_dialog import UserMsg, UserYesNo, UserInput, UserCheckBox, UserChoice
from bliss.shell.cli.user_dialog import BlissWizard
from bliss.shell.cli.pt_widgets import BlissDialog, display
'''
dlg = UserYesNo(label="Do you want to save changes?")
response=display(dlg, title='Bliss manager')
if response is True:
dlg = UserMsg(label="Changes saved to disk.")
display(dlg, title='Bliss manager')
dlg1 = UserInput(label="User name")
dlg2 = UserCheckBox(label="Enable auto-save", defval=True)
dlg3 = UserChoice(label="File format", values=[('txt','.txt'), ('hdf5','.hdf5'), ('tiff','.tiff')])
BlissDialog( [ [dlg1], [dlg2, dlg3] ] , title='Bliss manager',paddings=(3,3)).show()
bdg1 = BlissDialog( ... )
bdg2 = BlissDialog( ... ) --> OK/Cancel
BlissWizard([bdg1, bdg2]).show()
'''
sc=static.get_config()
sc.reload()
par26=sc.get_config('par26')
def par26menu ():
dlg_exit = UserChoice(label="on EXIT:",
values=[('mem','Save to memory'),('beacon','Save to disk')]
)
dlg_id = UserCheckBox(label="Gap tracking", defval=False)
rep = BlissDialog([[dlg_id],[dlg_exit]], title='ID26 control parameters').show()
if rep not False:
if rep[dlg_exit] is 'mem':
par26['id_linked'].set('on' if rep[dlg_id] is True else 'off')
if rep[dlg_exit] is 'beacon':
par26.save()
return rep
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment