function(toClose) {
        var me = this;
        if (toClose.active && me.items.getCount() > 1) {
            return (me.previousTab && me.previousTab !== toClose && !me.previousTab.disabled) ? me.previousTab : (toClose.next('tab[disabled=false]') || toClose.prev('tab[disabled=false]'));
        }
    }
function(toClose) {
        var me = this;
        if (toClose.active && me.items.getCount() > 1) {
            return (me.previousTab && me.previousTab !== toClose && !me.previousTab.disabled) ? me.previousTab : (toClose.next('tab[disabled=false]') || toClose.prev('tab[disabled=false]'));
        }
    }
function ( toClose ) { var me = this ; if ( toClose . active && me . items . getCount ( ) > 1 ) { return ( me . previousTab && me . previousTab !== toClose && ! me . previousTab . disabled ) ? me . previousTab : ( toClose . next ( 'tab[disabled=false]' ) || toClose . prev ( 'tab[disabled=false]' ) ) ; } }
private - used by TabPanel too. Works out the next tab to activate when one tab is closed.
private - used by TabPanel too . Works out the next tab to activate when one tab is closed .