Draft: fix wrong selection after commands (improved)

The previous fix was not correct. Some commands would cause a crash and several files were missed.

Forum topic reporting a crash:
https://forum.freecad.org/viewtopic.php?t=85243
This commit is contained in:
Roy-043
2024-02-16 10:56:10 +01:00
parent 01ad6adacc
commit 0beda2c1bd
32 changed files with 138 additions and 119 deletions

View File

@@ -240,9 +240,9 @@ def offset(obj, delta, copy=False, bind=False, sym=False, occ=False):
print("unsupported object") # TODO
newobj = obj
if copy and params.get_param("selectBaseObjects"):
gui_utils.select(newobj)
else:
gui_utils.select(obj)
else:
gui_utils.select(newobj)
if delete:
App.ActiveDocument.removeObject(delete)
return newobj