13e407d43d58c355579a3d7b7564ff199a991912
tdreszer
  Tue Apr 12 11:34:20 2011 -0700
Fix for redmine 1411. Unchecking subtrack failed to grey matrix CB in 1D matrix.
diff --git src/hg/js/hui.js src/hg/js/hui.js
index 2359c11..4278b3a 100644
--- src/hg/js/hui.js
+++ src/hg/js/hui.js
@@ -409,31 +409,31 @@
 }
 
 function matCBsWhichAreComplete(complete)
 {
 // Returns a list of currently indeterminate matCBs.  This is encapsulated to keep consistent with matCbComplete()
     if(complete)
         return $("input.matCB").not(".halfVis");
     else
         return $("input.matCB.halfVis");
 }
 
 function matCbFindFromSubCb(subCB)
 {
 // returns the one matCB associated with a subCB (or undefined)
     var classList =  $( subCB ).attr("class").split(" ");
-    classes = '.' + classList.slice(1,3).join('.');   // How to get only X and Y classes?  Assume they are the first 2 ("subCB GM12878 H3K4me3 rep1 p1" we only want ".GM12878.H3K4me3")
+    var classes = '.' + classList.slice(1,classList.length - 1).join('.');   // How to get only X and Y classes?  Assume they are the first 2 ("subCB GM12878 H3K4me3 rep1 p1" we only want ".GM12878.H3K4me3")
     // At this point classes has been converted from "subCB 1GM12878 CTCF rep1 cHot" to ".1GM12878.CTCF"
     var matCB = $("input.matCB"+classes); // NOte, this works for filtering multiple classes because we want AND
     if(matCB.length == 1)
         return matCB;
     else
         return undefined;
 }
 
 function matAbcCBfindFromSubCb(subCB)
 {
 // returns the abcCBs associated with a subCB (or undefined)
     var abcCBs = $("input.matCB.abc");
     if( abcCBs.length > 0 ) {
         var classList =  $( subCB ).attr("class").split(" ");
         classList = aryRemove(classList,"subCB");