aboutsummaryrefslogtreecommitdiffstats
path: root/ui/jquery.ui.tabs.js
diff options
context:
space:
mode:
authorScott González <scott.gonzalez@gmail.com>2012-06-13 10:40:41 -0400
committerScott González <scott.gonzalez@gmail.com>2012-06-13 10:40:41 -0400
commit6d9c77a26857d8bb0c4ea742163b026325dbc8c1 (patch)
tree03897d27a609e4663d981e052425e6a49412b572 /ui/jquery.ui.tabs.js
parent9608e981498846b3727cc4dad723a7fa7252fd86 (diff)
downloadjquery-ui-6d9c77a26857d8bb0c4ea742163b026325dbc8c1.tar.gz
jquery-ui-6d9c77a26857d8bb0c4ea742163b026325dbc8c1.zip
Tabs: Better event binding/unbinding.
Diffstat (limited to 'ui/jquery.ui.tabs.js')
-rw-r--r--ui/jquery.ui.tabs.js7
1 files changed, 3 insertions, 4 deletions
diff --git a/ui/jquery.ui.tabs.js b/ui/jquery.ui.tabs.js
index 5878a56a1..21736641f 100644
--- a/ui/jquery.ui.tabs.js
+++ b/ui/jquery.ui.tabs.js
@@ -693,12 +693,11 @@ $.widget( "ui.tabs", {
.removeClass( "ui-tabs-anchor" )
.removeAttr( "role" )
.removeAttr( "tabIndex" )
- .unbind( ".tabs" )
.removeData( "href.tabs" )
.removeData( "load.tabs" )
.removeUniqueId();
- this.tabs.unbind( ".tabs" ).add( this.panels ).each(function() {
+ this.tabs.add( this.panels ).each(function() {
if ( $.data( this, "ui-tabs-destroy" ) ) {
$( this ).remove();
} else {
@@ -880,7 +879,7 @@ if ( $.uiBackCompat !== false ) {
var that = this;
- this.element.bind( "tabsbeforeload.tabs", function( event, ui ) {
+ this._on({ tabsbeforeload: function( event, ui ) {
// tab is already cached
if ( $.data( ui.tab[ 0 ], "cache.tabs" ) ) {
event.preventDefault();
@@ -905,7 +904,7 @@ if ( $.uiBackCompat !== false ) {
$.data( ui.tab[ 0 ], "cache.tabs", true );
}
});
- });
+ }});
},
_setOption: function( key, value ) {