added first version of a backup system (#37)

Co-authored-by: Dominik Demuth <dominik.demuth@physik.tu-darmstadt.de>
Reviewed-on: #37
This commit is contained in:
2023-04-05 17:50:06 +00:00
parent 2fbaa94109
commit 43285b4bd5
3 changed files with 27 additions and 2 deletions

View File

@ -180,7 +180,10 @@ class UpperManagement(QtCore.QObject):
graph.active = active
graph.listWidget.blockSignals(True)
for i, l in enumerate(g['in_legend']):
graph.listWidget.item(i).setCheckState(l)
try:
graph.listWidget.item(i).setCheckState(QtCore.Qt.Checked if l else QtCore.Qt.Unchecked)
except AttributeError:
pass
graph.listWidget.blockSignals(False)
# set unchecked in tree and hide/show in plot