Showing 1,485 of 3,294 total issues
Function showDropdown
has 43 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
DropdownButton.prototype.showDropdown = function () {
// Act like a plain old button if no items to show
if (!this.items.length) {
return;
}
Function _handleMouseEnterOrExitScaleSticker
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
ImageView.prototype._handleMouseEnterOrExitScaleSticker = function (offsetX, offsetY) {
var imagePos = this.$imagePreview.position(),
scaleDivPos = this.$imageScale.position(),
imgWidth = this.$imagePreview.width(),
imgHeight = this.$imagePreview.height(),
Function setInlineWidgetHeight
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
Editor.prototype.setInlineWidgetHeight = function (inlineWidget, height, ensureVisible) {
var self = this,
node = inlineWidget.htmlContent,
oldHeight = (node && $(node).height()) || 0,
changed = (oldHeight !== height),
Function shake
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
$.effects.effect.shake = function( o, done ) {
var el = $( this ),
props = [ "position", "top", "bottom", "left", "right", "height", "width" ],
mode = $.effects.setMode( el, o.mode || "effect" ),
Function conststatement
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
var conststatement = stmt('const', function (prefix) {
var id, name, value;
this.first = [];
for (;;) {
Function add
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
add: function( url, label, index ) {
if ( index === undefined ) {
index = this.anchors.length;
}
Function varstatement
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
var varstatement = stmt('var', function (prefix) {
// JavaScript does not have block scope. It only has function scope. So,
// declaring a variable in a block can have unexpected consequences.
var id, name, value;
Function _makeResizable
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_makeResizable: function( handles ) {
handles = (handles === undefined ? this.options.resizable : handles);
var that = this,
options = this.options,
// .ui-resizable has position: relative defined in the stylesheet
Function directives
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function directives() {
var i, p, pn;
for (;;) {
if (nexttoken.id === "(string)") {
Function load
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
load: function( index, event ) {
index = this._getIndex( index );
var that = this,
tab = this.tabs.eq( index ),
anchor = tab.find( ".ui-tabs-anchor" ),
Function scale
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
$.effects.effect.scale = function( o, done ) {
// Create element
var el = $( this ),
options = $.extend( true, {}, o ),
Function loadMetadata
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function loadMetadata(folder) {
var packageJSONFile = FileSystem.getFileForPath(folder + "/package.json"),
disabledFile = FileSystem.getFileForPath(folder + "/.disabled"),
baseName = FileUtils.getBaseName(folder),
result = new $.Deferred(),
Function writeFile
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function writeFile(path, data, options, callback) {
var encoding = options.encoding || "utf8",
preserveBOM = options.preserveBOM;
function _finishWrite(created) {
Function _updateFromPrefs
has 42 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function _updateFromPrefs(pref) {
var newMapping = PreferencesManager.get(pref),
newNames = Object.keys(newMapping),
state = _prefState[pref],
last = state.last,
Consider simplifying this complex logical expression. Open
Open
if (isBlockComment) {
// Save the initial position to start searching for the suffix from here
initialPos = _.cloneDeep(ctx.pos);
// Find the position of the start of the prefix
Consider simplifying this complex logical expression. Open
Open
if ( ( ( $target[0].id != $.datepicker._mainDivId &&
$target.parents('#' + $.datepicker._mainDivId).length == 0 &&
!$target.hasClass($.datepicker.markerClassName) &&
!$target.closest("." + $.datepicker._triggerClass).length &&
$.datepicker._datepickerShowing && !($.datepicker._inDialog && $.blockUI) ) ) ||
Consider simplifying this complex logical expression. Open
Open
if (this.floating && horizontalDirection) {
return ((horizontalDirection == "right" && isOverRightHalf) || (horizontalDirection == "left" && !isOverRightHalf));
} else {
return verticalDirection && ((verticalDirection == "down" && isOverBottomHalf) || (verticalDirection == "up" && !isOverBottomHalf));
}
Consider simplifying this complex logical expression. Open
Open
if(!(/^(document|window|parent)$/).test(o.containment)) {
var ce = $(o.containment)[0];
var co = $(o.containment).offset();
var over = ($(ce).css("overflow") != 'hidden');
Function init
has 41 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function init(domainManager) {
_domainManager = domainManager;
if (!domainManager.hasDomain("OpenWithExternalApplication")) {
domainManager.registerDomain("OpenWithExternalApplication", {major: 0, minor: 1});
Function initiateAutoUpdate
has 41 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function initiateAutoUpdate(updateParams) {
_updateParams = updateParams;
downloadAttemptsRemaining = MAX_DOWNLOAD_ATTEMPTS;
initializeState()