efd31a21fbdbea22203abd6eefc1e1354132c330 max Tue Oct 15 07:02:31 2024 -0700 tiny improvement for composites: when a track is not active, give an indicator that user should activate the subtrack first to configure it. not ideal, but some small step forward, refs #23169 diff --git src/hg/js/subCfg.js src/hg/js/subCfg.js index e7e843d..a998350 100644 --- src/hg/js/subCfg.js +++ src/hg/js/subCfg.js @@ -728,32 +728,35 @@ if (cfg) $(cfg).hide(); } } }, cfgToggle: function (wrench,subtrack) { // Opens/closes subtrack cfg dialog, populating if empty var cfg = normed($(document.getElementById("div_cfg_"+subtrack))); if (!cfg) { warn("DEBUG: Can't find div_cfg_"+subtrack); return false; } if ($(cfg).css('display') === 'none') { - if ($(wrench).hasClass('disabled')) + if ($(wrench).hasClass('disabled')) { + alert("This track is not active. To configure this track, please make it visible first by clicking the checkbox, " + "then click the 'Configure' link."); return; + } // Don't allow if this composite is not enabled! // find the cb var tr = $(cfg).parents('tr').first(); var subCb = normed($(tr).find("input[name='"+subtrack+"_sel']")); if (!subCb) { warn("DEBUG: Can't find subCB for "+subtrack); return false; } //if (subCb.disabled === true) // || subCb.checked === false) if (isFauxDisabled(subCb,true)) return false; if (metadataIsVisible(subtrack)) metadataShowHide(subtrack,"",""); if ($(cfg).hasClass('filled'))