Franklinjagan / jsplumb

Automatically exported from code.google.com/p/jsplumb
0 stars 0 forks source link

Detach event fired 3 times when a connection is dragged away #52

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
As reported in Issue 47, the fix committed has the unwanted effect of firing a 
detach event 3 times when we try to delete a connection by dragging it 
somewhere empty.

It seems the stopEvent handler calls Endpoint.detach 2 times for the same 
connection, and Endpoint.detach being somewhat recursive we end with 3 calls to 
fireDetachEvent.

Original issue reported on code.google.com by sylvain....@gmail.com on 8 Dec 2010 at 1:48

GoogleCodeExporter commented 9 years ago
i can confirm this on the draggableConnectors demo.

it also does some craziness when you press 'clear plumbing' (which is hooked up 
to jsPlumb.detachEverything)

targeting 1.2.5.

Original comment by simon.po...@gmail.com on 8 Dec 2010 at 9:04

GoogleCodeExporter commented 9 years ago
the case that you mentioned is fixed on trunk now; the other craziness is due 
to dragged endpoints not being cleaned properly.  watch this space.

Original comment by simon.po...@gmail.com on 8 Dec 2010 at 10:03

GoogleCodeExporter commented 9 years ago
dragged endpoints are all cleaned up correctly now.  case closed.

for now you'll have to use the dev scripts for this.  will be released in 1.2.5.

Original comment by simon.po...@gmail.com on 9 Dec 2010 at 8:19

GoogleCodeExporter commented 9 years ago

Original comment by simon.po...@gmail.com on 24 Mar 2011 at 10:49