js/components/carousel.js
function(index) {
        if (this.animating) {
            return;
        }

        var indexes = this._getIndex(index),
            cloneIndex = indexes[0], // The index including clones
            visualIndex = indexes[1]; // The index excluding clones

        // Exit early if jumping to same index
        if (visualIndex === this.index) {
            return;
        }

        this.fireEvent('jumping', [this.index]);

        // Update tabs and items state
        this._updateTabs(visualIndex);
        this._updateItems(cloneIndex);

        // Animate and move the items
        this._beforeCycle();

        if (this.options.animation === 'fade') {
            this.items
                .conceal(true)
                .eq(visualIndex)
                    .transitionend(this._afterCycle.bind(this))
                    .reveal(true);

        } else {
            this.container
                .transitionend(this._afterCycle.bind(this))
                .css(this._position, -this._getSizeSum(cloneIndex));
        }

        // Store the index
        this.index = visualIndex;

        this.reset();
        this.fireEvent('jumped', [visualIndex]);
    }
function(index) {
        if (this.animating) {
            return;
        }

        var indexes = this._getIndex(index),
            cloneIndex = indexes[0], // The index including clones
            visualIndex = indexes[1]; // The index excluding clones

        // Exit early if jumping to same index
        if (visualIndex === this.index) {
            return;
        }

        this.fireEvent('jumping', [this.index]);

        // Update tabs and items state
        this._updateTabs(visualIndex);
        this._updateItems(cloneIndex);

        // Animate and move the items
        this._beforeCycle();

        if (this.options.animation === 'fade') {
            this.items
                .conceal(true)
                .eq(visualIndex)
                    .transitionend(this._afterCycle.bind(this))
                    .reveal(true);

        } else {
            this.container
                .transitionend(this._afterCycle.bind(this))
                .css(this._position, -this._getSizeSum(cloneIndex));
        }

        // Store the index
        this.index = visualIndex;

        this.reset();
        this.fireEvent('jumped', [visualIndex]);
    }
function ( index ) { if ( this . animating ) { return ; } var indexes = this . _getIndex ( index ) , cloneIndex = indexes [ 0 ] , // The index including clones visualIndex = indexes [ 1 ] ; // The index excluding clones // Exit early if jumping to same index if ( visualIndex === this . index ) { return ; } this . fireEvent ( 'jumping' , [ this . index ] ) ; // Update tabs and items state this . _updateTabs ( visualIndex ) ; this . _updateItems ( cloneIndex ) ; // Animate and move the items this . _beforeCycle ( ) ; if ( this . options . animation === 'fade' ) { this . items . conceal ( true ) . eq ( visualIndex ) . transitionend ( this . _afterCycle . bind ( this ) ) . reveal ( true ) ; } else { this . container . transitionend ( this . _afterCycle . bind ( this ) ) . css ( this . _position , - this . _getSizeSum ( cloneIndex ) ) ; } // Store the index this . index = visualIndex ; this . reset ( ) ; this . fireEvent ( 'jumped' , [ visualIndex ] ) ; }
Go to the item indicated by the index number.

@param {Number} index
Go to the item indicated by the index number .