diff options
author | Scott González <scott.gonzalez@gmail.com> | 2011-05-10 14:04:50 -0400 |
---|---|---|
committer | Scott González <scott.gonzalez@gmail.com> | 2011-05-10 14:04:50 -0400 |
commit | 85ac420a1e4281ee7f361e847d3cad72fa58525e (patch) | |
tree | 21f3e78605024015cf5cd1e9c1b1d78e104bd1d2 /ui/jquery.ui.tabs.js | |
parent | 7fddb1c5b5137887f6c145f54e47f946ceb9741d (diff) | |
download | jquery-ui-85ac420a1e4281ee7f361e847d3cad72fa58525e.tar.gz jquery-ui-85ac420a1e4281ee7f361e847d3cad72fa58525e.zip |
Tabs: Fixed select event.
Diffstat (limited to 'ui/jquery.ui.tabs.js')
-rw-r--r-- | ui/jquery.ui.tabs.js | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/ui/jquery.ui.tabs.js b/ui/jquery.ui.tabs.js index dca6a538d..cce50d3e7 100644 --- a/ui/jquery.ui.tabs.js +++ b/ui/jquery.ui.tabs.js @@ -153,14 +153,6 @@ $.widget( "ui.tabs", { return hash ? hash.replace( /:/g, "\\:" ) : ""; }, - _ui: function( tab, panel ) { - return { - tab: tab, - panel: panel, - index: this.anchors.index( tab ) - }; - }, - refresh: function() { var self = this, options = this.options, @@ -651,6 +643,15 @@ $.extend( $.ui.tabs, { // DEPRECATED if ( $.uiBackCompat !== false ) { + // helper method for a lot of the back compat extensions + $.ui.tabs.prototype._ui = function( tab, panel ) { + return { + tab: tab, + panel: panel, + index: this.anchors.index( tab ) + }; + }; + // url method (function( $, prototype ) { prototype.url = function( index, url ) { @@ -975,7 +976,7 @@ if ( $.uiBackCompat !== false ) { if ( !ret ) { return false; } - if ( type === "beforeActivate" ) { + if ( type === "beforeActivate" && data.newTab.length ) { ret = _trigger.call( this, "select", event, { tab: data.newTab[ 0], panel: data.newPanel[ 0 ], |