mirror of https://github.com/m-labs/artiq.git
dashboard, browser: fix missing recompute arguments
This commit is contained in:
parent
d0f893c01c
commit
aea5f04d74
|
@ -23,7 +23,7 @@ class _ArgumentEditor(EntryTreeWidget):
|
|||
self._dock = dock
|
||||
|
||||
if not self._dock.arguments:
|
||||
self.addTopLevelItem(QtWidgets.QTreeWidgetItem(["No arguments"]))
|
||||
self.insertTopLevelItem(0, QtWidgets.QTreeWidgetItem(["No arguments"]))
|
||||
|
||||
for name, argument in self._dock.arguments.items():
|
||||
self.set_argument(name, argument)
|
||||
|
|
|
@ -34,7 +34,7 @@ class _ArgumentEditor(EntryTreeWidget):
|
|||
arguments = self.manager.get_submission_arguments(self.expurl)
|
||||
|
||||
if not arguments:
|
||||
self.addTopLevelItem(QtWidgets.QTreeWidgetItem(["No arguments"]))
|
||||
self.insertTopLevelItem(0, QtWidgets.QTreeWidgetItem(["No arguments"]))
|
||||
|
||||
for name, argument in arguments.items():
|
||||
self.set_argument(name, argument)
|
||||
|
|
|
@ -45,7 +45,6 @@ class EntryTreeWidget(QtWidgets.QTreeWidget):
|
|||
|
||||
self.bottom_item = QtWidgets.QTreeWidgetItem()
|
||||
self.addTopLevelItem(self.bottom_item)
|
||||
self.bottom_item.setHidden(True)
|
||||
|
||||
def set_argument(self, key, argument):
|
||||
self._arguments[key] = argument
|
||||
|
@ -60,9 +59,6 @@ class EntryTreeWidget(QtWidgets.QTreeWidget):
|
|||
widgets["entry"] = entry
|
||||
widgets["widget_item"] = widget_item
|
||||
|
||||
if len(self._arguments) > 1:
|
||||
self.bottom_item.setHidden(False)
|
||||
|
||||
for col in range(3):
|
||||
widget_item.setBackground(col, self.gradient)
|
||||
font = widget_item.font(0)
|
||||
|
@ -73,7 +69,6 @@ class EntryTreeWidget(QtWidgets.QTreeWidget):
|
|||
self.insertTopLevelItem(self.indexFromItem(self.bottom_item).row(), widget_item)
|
||||
else:
|
||||
self._get_group(argument["group"]).addChild(widget_item)
|
||||
self.bottom_item.setHidden(False)
|
||||
fix_layout = LayoutWidget()
|
||||
widgets["fix_layout"] = fix_layout
|
||||
fix_layout.addWidget(entry)
|
||||
|
|
Loading…
Reference in New Issue