ericabouaf / wireit

A javascript wiring library to create web wirable interfaces for dataflow applications, visual programming languages or graphical modeling.
http://neyric.github.io/wireit/docs/
Other
520 stars 90 forks source link

dragdrop intersect mode #14

Closed kwek closed 12 years ago

kwek commented 14 years ago

It see that when the wireit lib is included it sets the global YAHOO.util.DDM.mode to YAHOO.util.DDM.INTERSECT. Because we intensively use drag 'n drop in our application this seriously affects performance (intersect mode is slower than point). I wasn't able to do that anymore if i disable the intersect mode so it seems that this is needed to detect when a wire is over a terminal.

Is it an idea to only change YAHOO.util.DDM.mode on startDrag / endDrag in WireIt.Terminal? Then the intersect mode is only active when dragging a wire. This fixed the issue for us but it might be nice to have this included in master.

ericabouaf commented 14 years ago

Do you just set YAHOO.util.DDM.mode = YAHOO.util.DDM.INTERSECT in startDrag YAHOO.util.DDM.mode = YAHOO.util.DDM.POINT in endDrag ?