style(legacy): format (#2039)

This commit is contained in:
Jonas L 2022-08-10 13:38:19 +02:00 committed by GitHub
parent 7082c9693d
commit 1550d44ac5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
122 changed files with 18369 additions and 15819 deletions

View file

@ -1,50 +1,51 @@
var AIRTIME = (function(AIRTIME) {
var mod, DEFAULT_CLASS = 'ui-button ui-state-default', DISABLED_CLASS = 'ui-state-disabled';
var AIRTIME = (function (AIRTIME) {
var mod,
DEFAULT_CLASS = "ui-button ui-state-default",
DISABLED_CLASS = "ui-state-disabled";
if (AIRTIME.button === undefined) {
AIRTIME.button = {};
if (AIRTIME.button === undefined) {
AIRTIME.button = {};
}
mod = AIRTIME.button;
mod.isDisabled = function (c, useParent) {
var button = $("." + c);
if (useParent) {
button = button.parent();
}
mod = AIRTIME.button;
mod.isDisabled = function(c, useParent) {
var button = $("." + c);
if (useParent) {
button = button.parent();
}
if (button.hasClass(DISABLED_CLASS)) {
return true;
}
if (button.hasClass(DISABLED_CLASS)) {
return true;
}
return false;
};
return false;
};
mod.enableButton = function (c, useParent) {
if (useParent) {
var button = $("." + c).parent();
} else {
var button = $("." + c);
}
mod.enableButton = function(c, useParent) {
if (useParent) {
var button = $("." + c).parent();
} else {
var button = $("." + c);
}
if (button.hasClass(DISABLED_CLASS)) {
button.removeClass(DISABLED_CLASS);
button.removeAttr("disabled");
}
};
if (button.hasClass(DISABLED_CLASS)) {
button.removeClass(DISABLED_CLASS);
button.removeAttr('disabled');
}
};
mod.disableButton = function (c, useParent) {
if (useParent) {
var button = $("." + c).parent();
} else {
var button = $("." + c);
}
mod.disableButton = function(c, useParent) {
if (useParent) {
var button = $("." + c).parent();
} else {
var button = $("." + c);
}
if (!button.hasClass(DISABLED_CLASS)) {
button.addClass(DISABLED_CLASS);
button.attr("disabled", "disabled");
}
};
if (!button.hasClass(DISABLED_CLASS)) {
button.addClass(DISABLED_CLASS);
button.attr('disabled', 'disabled');
}
};
return AIRTIME;
}(AIRTIME || {}));
return AIRTIME;
})(AIRTIME || {});