oddtopus / flamingo

FreeCAD - flamingo workbench
GNU Lesser General Public License v3.0
32 stars 13 forks source link

pipeCmd.join() does not remove port marks on deleted objects #8

Closed rkrenzler closed 6 years ago

rkrenzler commented 6 years ago

How to reproduce:

  1. Create new document.
  2. Insert a pipe.
  3. Click on the button which joins fittings (pipeCmd.join() command).
  4. Select the pipe. Green triangles apear on both sides of the pipe.
  5. Delete the pipe.
  6. The pipe is deleted but the green triangles are still there.
oddtopus commented 6 years ago

Press ESC before deleting the pipe. That terminates the observer class neatly and remove both the callbacks and the pure graphical elements. I know it's tricky to deal with that. Just remember that the arrows are independent objects that do not have a Shape and Geometry like other solids displayed but are only graphics sketched in the view-scene (check "Inventor Mentor" for more about that). Anyway, if something fails or you forget to press ESC, when you save and close the document the arrows disappear.

2018-04-01 12:32 GMT+02:00 rkrenzler notifications@github.com:

How to reproduce:

  1. Create new document.
  2. Insert a pipe.
  3. Click on the button which joins fittings (pipeCmd.join() command).
  4. Select the pipe. Green triangles apear on both sides of the pipe.
  5. Delete the pipe.
  6. The pipe is deleted but the green triangles are still there.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/oddtopus/flamingo/issues/8, or mute the thread https://github.com/notifications/unsubscribe-auth/ATpKXX3HHc0mfSBq7m6-RU7bRT6YLxsAks5tkKzCgaJpZM4TCySC .

rkrenzler commented 6 years ago

Thanks for the explanation. I will try to find out, if it is possible to clean up this kind of objects. Sometimes the command crashes and leaves the arrows too.

oddtopus commented 6 years ago

Added dialog (with "reset" button). Thus by leaving it, all the arrows will be closed neatly.