aboutsummaryrefslogtreecommitdiffstats
path: root/ui/widget.js
diff options
context:
space:
mode:
authorAlexander Schmitz <arschmitz@gmail.com>2015-05-13 22:02:32 -0400
committerAlexander Schmitz <arschmitz@gmail.com>2015-05-20 14:27:57 -0400
commite543253468398ab0c3f3603d9523a4673f1491ea (patch)
tree8c93efcf3ee36e62186ec1bc43acf3ee99973c60 /ui/widget.js
parent24f1ce9ea046607ae9d0611aefbe5bbd636f8d32 (diff)
downloadjquery-ui-e543253468398ab0c3f3603d9523a4673f1491ea.tar.gz
jquery-ui-e543253468398ab0c3f3603d9523a4673f1491ea.zip
Widget: Remove core event/alias and deprecated module dependencies
Diffstat (limited to 'ui/widget.js')
-rw-r--r--ui/widget.js12
1 files changed, 6 insertions, 6 deletions
diff --git a/ui/widget.js b/ui/widget.js
index ae72c709b..603a49136 100644
--- a/ui/widget.js
+++ b/ui/widget.js
@@ -313,14 +313,14 @@ $.Widget.prototype = {
// we can probably remove the unbind calls in 2.0
// all event bindings should go through this._on()
this.element
- .unbind( this.eventNamespace )
+ .off( this.eventNamespace )
.removeData( this.widgetFullName );
this.widget()
- .unbind( this.eventNamespace )
+ .off( this.eventNamespace )
.removeAttr( "aria-disabled" );
// clean up events and states
- this.bindings.unbind( this.eventNamespace );
+ this.bindings.off( this.eventNamespace );
},
_destroy: $.noop,
@@ -535,9 +535,9 @@ $.Widget.prototype = {
eventName = match[ 1 ] + instance.eventNamespace,
selector = match[ 2 ];
if ( selector ) {
- delegateElement.delegate( selector, eventName, handlerProxy );
+ delegateElement.on( eventName, selector, handlerProxy );
} else {
- element.bind( eventName, handlerProxy );
+ element.on( eventName, handlerProxy );
}
} );
},
@@ -545,7 +545,7 @@ $.Widget.prototype = {
_off: function( element, eventName ) {
eventName = ( eventName || "" ).split( " " ).join( this.eventNamespace + " " ) +
this.eventNamespace;
- element.unbind( eventName ).undelegate( eventName );
+ element.off( eventName ).off( eventName );
// Clear the stack to avoid memory leaks (#10056)
this.bindings = $( this.bindings.not( element ).get() );