As a drag event stops, I must find if my div collides with any other node. So, on the "stop" event, I write a loop that will check for collisions with items of the same type.
$('.article').draggable({
stop: function(event, ui){
$(".article").each(function (i) {
if(this == ui.helper){
return;
}
// Test collisions
});
}
});
Now, I can't find the way to exclude itself from that loop. I expected this and ui.helper to be the same, but they're considered separate elements. How should I do this?
Thanks,