aboutsummaryrefslogtreecommitdiffstats
path: root/ui/jquery.ui.tabs.js
diff options
context:
space:
mode:
authorScott González <scott.gonzalez@gmail.com>2012-06-14 12:33:16 -0400
committerScott González <scott.gonzalez@gmail.com>2012-06-14 12:33:16 -0400
commitff39bed57a05ca060033187b8aecebafab357f78 (patch)
treee82f4c3faa3b5269f0f86e3f186a6f3024ad7466 /ui/jquery.ui.tabs.js
parent00d4beb0ca4a99933bb7e786a1dd50618c180a0b (diff)
downloadjquery-ui-ff39bed57a05ca060033187b8aecebafab357f78.tar.gz
jquery-ui-ff39bed57a05ca060033187b8aecebafab357f78.zip
Widget: Added _off() for removing event handlers. Fixes #7795 - Widget: _on and _off.
Diffstat (limited to 'ui/jquery.ui.tabs.js')
-rw-r--r--ui/jquery.ui.tabs.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/ui/jquery.ui.tabs.js b/ui/jquery.ui.tabs.js
index 21736641f..aed4ba8fb 100644
--- a/ui/jquery.ui.tabs.js
+++ b/ui/jquery.ui.tabs.js
@@ -58,7 +58,7 @@ $.widget( "ui.tabs", {
.addClass( "ui-tabs ui-widget ui-widget-content ui-corner-all" )
.toggleClass( "ui-tabs-collapsible", options.collapsible )
// Prevent users from focusing disabled tabs via click
- .delegate( ".ui-tabs-nav > li", "mousedown.tabs", function( event ) {
+ .delegate( ".ui-tabs-nav > li", "mousedown" + this.eventNamespace, function( event ) {
if ( $( this ).is( ".ui-state-disabled" ) ) {
event.preventDefault();
}
@@ -69,7 +69,7 @@ $.widget( "ui.tabs", {
// We don't have to worry about focusing the previously focused
// element since clicking on a non-focusable element should focus
// the body anyway.
- .delegate( ".ui-tabs-anchor", "focus.tabs", function() {
+ .delegate( ".ui-tabs-anchor", "focus" + this.eventNamespace, function() {
if ( $( this ).closest( "li" ).is( ".ui-state-disabled" ) ) {
this.blur();
}
@@ -480,7 +480,7 @@ $.widget( "ui.tabs", {
});
}
- this.anchors.add( this.tabs ).add( this.panels ).unbind( ".tabs" );
+ this._off( this.anchors.add( this.tabs ).add( this.panels ) );
this._on( this.anchors, events );
this._on( this.tabs, { keydown: "_tabKeydown" } );
this._on( this.panels, { keydown: "_panelKeydown" } );