Showing 161 of 426 total issues
Function _optionDatepicker
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_optionDatepicker: function(target, name, value) {
var inst = this._getInst(target);
if (arguments.length == 2 && typeof name == 'string') {
return (name == 'defaults' ? $.extend({}, $.datepicker._defaults) :
(inst ? (name == 'all' ? $.extend({}, inst.settings) :
Function _initSource
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_initSource: function() {
var array, url,
that = this;
if ( $.isArray(this.options.source) ) {
array = this.options.source;
Function puff
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
$.effects.effect.puff = function( o, done ) {
var elem = $( this ),
mode = $.effects.setMode( elem, o.mode || "hide" ),
hide = mode === "hide",
percent = parseInt( o.percent, 10 ) || 150,
Function refreshPositions
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
refreshPositions: function(fast) {
//This has to be redone because due to the item being moved out/into the offsetParent, the offsetParent's position will change
if(this.offsetParent && this.helper) {
this.offset.parent = this._getParentOffset();
Function highlight
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
$.effects.effect.highlight = function( o, done ) {
var elem = $( this ),
props = [ "backgroundImage", "backgroundColor", "opacity" ],
mode = $.effects.setMode( elem, o.mode || "show" ),
animation = {
Function _create
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_create: function() {
var that = this;
this.element.addClass("ui-selectable");
Function _mouseStop
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_mouseStop: function(event) {
//If we are using droppables, inform the manager about the drop
var dropped = false;
if ($.ui.ddmanager && !this.options.dropBehaviour)
Function values
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
values: function( index, newValue ) {
var vals,
newValues,
i;
Function transfer
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
$.effects.effect.transfer = function( o, done ) {
var elem = $( this ),
target = $( o.to ),
targetFixed = target.css( "position" ) === "fixed",
body = $("body"),
Function left
has 27 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
left: function( position, data ) {
var within = data.within,
withinOffset = within.isWindow ? within.scrollLeft : within.offset.left,
outerWidth = within.width,
collisionPosLeft = position.left - data.collisionPosition.marginLeft,
Function top
has 27 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
top: function( position, data ) {
var within = data.within,
withinOffset = within.isWindow ? within.scrollTop : within.offset.top,
outerHeight = data.within.height,
collisionPosTop = position.top - data.collisionPosition.marginTop,
Function refresh
has 27 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
refresh: function() {
//See #8237 & #8828
var isDisabled = this.element.is( "input, button" ) ? this.element.is( ":disabled" ) : this.element.hasClass( "ui-button-disabled" );
if ( isDisabled !== this.options.disabled ) {
Function set
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
set: function( elem, value ) {
var parsed, curElem,
backgroundColor = "";
if ( jQuery.type( value ) !== "string" || ( parsed = stringParse( value ) ) ) {
Function position
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
$.fn.position = function( options ) {
if ( !options || !options.offset ) {
return _position.call( this, options );
}
var offset = options.offset.split( " " ),
Function focus
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
focus: function( event, item ) {
var nested, focused;
this.blur( event, event && event.type === "focus" );
this._scrollIntoView( item );
Consider simplifying this complex logical expression. Open
Open
if(!inst.snapElements[i].snapping && (ts || bs || ls || rs || first))
(inst.options.snap.snap && inst.options.snap.snap.call(inst.element, event, $.extend(inst._uiHash(), { snapItem: inst.snapElements[i].item })));
Consider simplifying this complex logical expression. Open
Open
if((this.options.revert == "invalid" && !dropped) || (this.options.revert == "valid" && dropped) || this.options.revert === true || ($.isFunction(this.options.revert) && this.options.revert.call(this.element, dropped))) {
var that = this;
$(this.helper).animate(this.originalPosition, parseInt(this.options.revertDuration, 10), function() {
if(that._trigger("stop", event) !== false) {
that._clear();
Consider simplifying this complex logical expression. Open
Open
if( this.options.tolerance == "pointer"
|| this.options.forcePointerForContainers
|| (this.options.tolerance != "pointer" && this.helperProportions[this.floating ? 'width' : 'height'] > item[this.floating ? 'width' : 'height'])
) {
return isOverElement;
Function _generateMonthYearHeader
has 8 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
_generateMonthYearHeader: function(inst, drawMonth, drawYear, minDate, maxDate,
secondary, monthNames, monthNamesShort) {
Consider simplifying this complex logical expression. Open
Open
if ($.datepicker._datepickerShowing)
switch (event.keyCode) {
case 9: $.datepicker._hideDatepicker();
handled = false;
break; // hide on tab out