Commit 4efe9d10 authored by sumpfralle's avatar sumpfralle

fix GUI update bugs


git-svn-id: https://pycam.svn.sourceforge.net/svnroot/pycam/trunk@507 bbaffbd6-741e-11dd-a85d-61de82d9cad9
parent fb30fe83
...@@ -1075,7 +1075,13 @@ class ProjectGui: ...@@ -1075,7 +1075,13 @@ class ProjectGui:
elif action == "delete": elif action == "delete":
# delete one item from the list # delete one item from the list
item = datalist[index] item = datalist[index]
if len(datalist) == 1: # Check if we need to remove items that depended on the currently
# deleted one.
if not datalist in (self.tool_list, self.process_list,
self.bounds_list):
# tasks do not depend on this list - just continue
pass
elif len(datalist) == 1:
# There are no replacements available for this item. # There are no replacements available for this item.
# Thus we need to remove _all_ tasks. # Thus we need to remove _all_ tasks.
while len(self.task_list) > 0: while len(self.task_list) > 0:
...@@ -1108,6 +1114,8 @@ class ProjectGui: ...@@ -1108,6 +1114,8 @@ class ProjectGui:
pass pass
# any new item can influence the "New task" button # any new item can influence the "New task" button
self.append_to_queue(self.update_tasklist_controls) self.append_to_queue(self.update_tasklist_controls)
# removing or adding "bounds" may change the visualization
self.append_to_queue(self.update_boundary_limits)
update_func(new_index=future_selection_index, update_func(new_index=future_selection_index,
skip_model_update=skip_model_update) skip_model_update=skip_model_update)
......
Markdown is supported
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