dist/toolkit.js
function(index, step, options) {
        var hideFirst = this.options.hideFirst;

        index += step;

        while (($.type(options[index]) === 'undefined') || options[index].disabled || (index === 0 && hideFirst)) {
            index += step;

            if (index >= options.length) {
                index = 0;
            } else if (index < 0) {
                index = options.length - 1;
            }
        }

        return index;
    }
function(index, step, options) {
        var hideFirst = this.options.hideFirst;

        index += step;

        while (($.type(options[index]) === 'undefined') || options[index].disabled || (index === 0 && hideFirst)) {
            index += step;

            if (index >= options.length) {
                index = 0;
            } else if (index < 0) {
                index = options.length - 1;
            }
        }

        return index;
    }
function ( index , step , options ) { var hideFirst = this . options . hideFirst ; index += step ; while ( ( $ . type ( options [ index ] ) === 'undefined' ) || options [ index ] . disabled || ( index === 0 && hideFirst ) ) { index += step ; if ( index >= options . length ) { index = 0 ; } else if ( index < 0 ) { index = options . length - 1 ; } } return index ; }
Loop through the options and determine the index to
Skip over missing options, disabled options, or hidden options.

@private
@param {Number} index
@param {Number} step
@param {jQuery} options
@returns {Number}
Loop through the options and determine the index to Skip over missing options disabled options or hidden options .