Skip to content

Commit

Permalink
Droppable: Use $.ui.intersect()
Browse files Browse the repository at this point in the history
Fixes #14963
  • Loading branch information
outofambit authored and scottgonzalez committed Oct 3, 2016
1 parent b9ffc34 commit fd30534
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions ui/widgets/droppable.js
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ $.widget( "ui.droppable", {
inst.accept.call(
inst.element[ 0 ], ( draggable.currentItem || draggable.element )
) &&
intersect(
$.ui.intersect(
draggable,
$.extend( inst, { offset: inst.element.offset() } ),
inst.options.tolerance, event
Expand Down Expand Up @@ -253,7 +253,7 @@ $.widget( "ui.droppable", {
}
} );

var intersect = $.ui.intersect = ( function() {
$.ui.intersect = ( function() {
function isOverAxis( x, reference, size ) {
return ( x >= reference ) && ( x < ( reference + size ) );
}
Expand Down Expand Up @@ -361,7 +361,7 @@ $.ui.ddmanager = {
return;
}
if ( !this.options.disabled && this.visible &&
intersect( draggable, this, this.options.tolerance, event ) ) {
$.ui.intersect( draggable, this, this.options.tolerance, event ) ) {
dropped = this._drop.call( this, event ) || dropped;
}

Expand Down Expand Up @@ -402,7 +402,7 @@ $.ui.ddmanager = {
}

var parentInstance, scope, parent,
intersects = intersect( draggable, this, this.options.tolerance, event ),
intersects = $.ui.intersect( draggable, this, this.options.tolerance, event ),
c = !intersects && this.isover ?
"isout" :
( intersects && !this.isover ? "isover" : null );
Expand Down

0 comments on commit fd30534

Please sign in to comment.