Better way to disable and reenable xfade button in playlist/sb editors

This commit is contained in:
Duncan Sommerville 2015-09-08 16:56:55 -04:00
parent 8c3f1cf535
commit e6494e7ff0
3 changed files with 5 additions and 5 deletions

View file

@ -406,7 +406,7 @@ var AIRTIME = (function(AIRTIME){
var empty = $pl.find(".spl_empty");
if (!show || empty.length > 0) {
//$pl.find("#spl_crossfade").hide();
$pl.find("#spl_crossfade").attr("disabled", "disabled");
} else {
//get list of playlist contents
var list = contents.children();
@ -416,9 +416,9 @@ var AIRTIME = (function(AIRTIME){
var last = list.last();
if (first.find(':first-child').children().attr('blockid') !== undefined &&
last.find(':first-child').children().attr('blockid') !== undefined) {
//$pl.find("#spl_crossfade").hide();
$pl.find("#spl_crossfade").attr("disabled", "disabled");
} else {
$pl.find("#spl_crossfade").show();
$pl.find("#spl_crossfade").removeAttr("disabled");
}
}