function with deactivated children
This commit is contained in:
parent
465fb0c09a
commit
625af5ec71
@ -70,7 +70,7 @@ class FitModelTree(QtWidgets.QTreeWidget):
|
|||||||
self.remove_function(item)
|
self.remove_function(item)
|
||||||
|
|
||||||
elif evt.key() == QtCore.Qt.Key.Key_Space:
|
elif evt.key() == QtCore.Qt.Key.Key_Space:
|
||||||
for item in self.treeWidget.selectedItems():
|
for item in self.selectedItems():
|
||||||
cs = item.checkState(0)
|
cs = item.checkState(0)
|
||||||
if cs == QtCore.Qt.CheckState.Unchecked:
|
if cs == QtCore.Qt.CheckState.Unchecked:
|
||||||
item.setCheckState(0, QtCore.Qt.CheckState.Checked)
|
item.setCheckState(0, QtCore.Qt.CheckState.Checked)
|
||||||
|
@ -26,6 +26,11 @@ class ModelFactory:
|
|||||||
if func['children']:
|
if func['children']:
|
||||||
right, _, _ = ModelFactory.create_from_list(func['children'], left_cnt=func['pos'],
|
right, _, _ = ModelFactory.create_from_list(func['children'], left_cnt=func['pos'],
|
||||||
func_order=func_order, param_len=param_len)
|
func_order=func_order, param_len=param_len)
|
||||||
|
|
||||||
|
if right is None:
|
||||||
|
right = func['func']
|
||||||
|
right_cnt = func['cnt']
|
||||||
|
else:
|
||||||
right_cnt = None
|
right_cnt = None
|
||||||
right = MultiModel(func['func'], right, func['children'][0]['op'], left_idx=func['cnt'], right_idx=None)
|
right = MultiModel(func['func'], right, func['children'][0]['op'], left_idx=func['cnt'], right_idx=None)
|
||||||
else:
|
else:
|
||||||
|
Loading…
Reference in New Issue
Block a user