mirror of
https://github.com/Yetangitu/ampache
synced 2025-10-04 02:09:23 +02:00
Fix some info level issues in codacy
This commit is contained in:
parent
5ab1ed2e93
commit
e6eda3850c
5 changed files with 76 additions and 75 deletions
|
@ -23,17 +23,17 @@ $(document).ready(function () {
|
|||
// Enable caching of AJAX responses, including script and jsonp
|
||||
cache: true
|
||||
});
|
||||
$('#notification').click(function() {
|
||||
$("#notification").click(function() {
|
||||
clearNotification();
|
||||
});
|
||||
});
|
||||
|
||||
function initTabs()
|
||||
{
|
||||
$('.default_hidden').hide();
|
||||
$(".default_hidden").hide();
|
||||
|
||||
$("#tabs li").click(function() {
|
||||
$("#tabs li").removeClass('tab_active');
|
||||
$("#tabs li").removeClass("tab_active");
|
||||
$(this).addClass("tab_active");
|
||||
$(".tab_content").hide();
|
||||
var selected_tab = $(this).find("a").attr("href");
|
||||
|
@ -46,16 +46,16 @@ function initTabs()
|
|||
$(function() {
|
||||
var rightmenu = $("#rightbar");
|
||||
var pos = rightmenu.offset();
|
||||
if (rightmenu.hasClass('rightbar-float')) {
|
||||
if (rightmenu.hasClass("rightbar-float")) {
|
||||
$(window).scroll(function() {
|
||||
var rightsubmenu = $("#rightbar .submenu");
|
||||
if ($(this).scrollTop() > (pos.top)) {
|
||||
rightmenu.addClass('fixedrightbar');
|
||||
rightsubmenu.addClass('fixedrightbarsubmenu');
|
||||
rightmenu.addClass("fixedrightbar");
|
||||
rightsubmenu.addClass("fixedrightbarsubmenu");
|
||||
}
|
||||
else if ($(this).scrollTop() <= pos.top && rightmenu.hasClass('fixedrightbar')) {
|
||||
rightmenu.removeClass('fixedrightbar');
|
||||
rightsubmenu.removeClass('fixedrightbarsubmenu');
|
||||
else if ($(this).scrollTop() <= pos.top && rightmenu.hasClass("fixedrightbar")) {
|
||||
rightmenu.removeClass("fixedrightbar");
|
||||
rightsubmenu.removeClass("fixedrightbarsubmenu");
|
||||
}
|
||||
else {
|
||||
rightmenu.offset({ left: pos.left, top: pos.top });
|
||||
|
@ -78,14 +78,14 @@ function flipField(field) {
|
|||
// updateText
|
||||
// Changes the specified elements innards. Used for the catalog mojo fluff.
|
||||
function updateText(field, value) {
|
||||
$('#'+field).html(value);
|
||||
$("#"+field).html(value);
|
||||
}
|
||||
|
||||
// toggleVisible
|
||||
// Toggles display type between block and none. Used for ajax loading div.
|
||||
function toggleVisible(element) {
|
||||
var target = $('#' + element);
|
||||
if (target.is(':visible')) {
|
||||
var target = $("#" + element);
|
||||
if (target.is(":visible")) {
|
||||
target.hide();
|
||||
} else {
|
||||
target.show();
|
||||
|
@ -97,15 +97,15 @@ function displayNotification(message, timeout) {
|
|||
if (notificationTimeout != null || !message) {
|
||||
clearNotification();
|
||||
}
|
||||
|
||||
|
||||
if (message) {
|
||||
if ($('#webplayer').css('display') !== 'block') {
|
||||
$('#notification').css('bottom', '20px');
|
||||
if ($("#webplayer").css("display") !== "block") {
|
||||
$("#notification").css("bottom", "20px");
|
||||
} else {
|
||||
$('#notification').css('bottom', '120px');
|
||||
$("#notification").css("bottom", "120px");
|
||||
}
|
||||
$('#notification-content').html(message);
|
||||
$('#notification').removeClass('notification-out');
|
||||
$("#notification-content").html(message);
|
||||
$("#notification").removeClass("notification-out");
|
||||
notificationTimeout = setTimeout(function() {
|
||||
clearNotification();
|
||||
}, timeout);
|
||||
|
@ -115,7 +115,7 @@ function displayNotification(message, timeout) {
|
|||
function clearNotification() {
|
||||
clearTimeout(notificationTimeout);
|
||||
notificationTimeout = null;
|
||||
$('#notification').addClass("notification-out");
|
||||
$("#notification").addClass("notification-out");
|
||||
}
|
||||
|
||||
// delayRun
|
||||
|
@ -136,7 +136,7 @@ function delayRun(element, time, method, page, source) {
|
|||
// IE issue fixed by Spocky, we have to use the iframe for Democratic Play &
|
||||
// Localplay, which don't actually prompt for a new file
|
||||
function reloadUtil(target) {
|
||||
$('#util_iframe').prop('src', target);
|
||||
$("#util_iframe").prop("src", target);
|
||||
}
|
||||
|
||||
function reloadDivUtil(target) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue