Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- jsPlumb.bind('beforeDrop', function(ci){ // Before new connection is created
- var src=ci.sourceId;
- var con=jsPlumb.getConnections({source:src}); // Get all source el. connection(s) except the new connection which is being established
- if(con.length!=0 && $('#'+src).hasClass('exit'))
- for(var i=0;i<con.length;i++)
- jsPlumb.detach(con[i]);
- return true; // true for establishing new connection
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement