Skip to content
Permalink
Browse files

Draggable tests: Don't use .on().

  • Loading branch information
scottgonzalez committed Mar 9, 2013
1 parent 8b1b34c commit 57051e8a7323e27fe159e5448b52666f1bdbc409
Showing with 2 additions and 2 deletions.
  1. +2 −2 tests/unit/draggable/draggable_test_helpers.js
@@ -60,7 +60,7 @@ TestHelpers.draggable = {

},
trackMouseCss : function( el ) {
el.on( "drag", function() {
el.bind( "drag", function() {
el.data( "last_dragged_cursor", $("body").css("cursor") );
});
},
@@ -69,7 +69,7 @@ TestHelpers.draggable = {
// appendTo ignored without being clone
el.draggable( "option", "helper", "clone" );

el.on( "drag", function(e,ui) {
el.bind( "drag", function(e,ui) {
// Get what parent is at time of drag
el.data( "last_dragged_parent", ui.helper.parent()[0] );
});

3 comments on commit 57051e8

@dwaddell

This comment has been minimized.

Copy link

dwaddell replied Mar 11, 2013

What is the purpose of this change? I am not questioning the change rather trying to learn, since there isn't a fixes #x or anything I am not following why you'd change a .on to a .bind.

Thanks,
Drew

@kborchers

This comment has been minimized.

Copy link
Member

kborchers replied Mar 11, 2013

jQuery UI supports back to jQuery 1.6 where .on() was not yet available thus the need to use .bind() in order for these tests to work with older versions of jQuery

@dwaddell

This comment has been minimized.

Copy link

dwaddell replied Mar 11, 2013

Thanks @kborchers, that makes sense.

Please sign in to comment.
You can’t perform that action at this time.