8954b57b721661b897012362dd8eb14452c9be01
kate
  Thu Oct 3 13:18:57 2019 -0700
Add filter activated to composite track center labels. refs #24252

diff --git src/hg/hgTracks/hgTracks.c src/hg/hgTracks/hgTracks.c
index a423a62..69f96b3 100644
--- src/hg/hgTracks/hgTracks.c
+++ src/hg/hgTracks/hgTracks.c
@@ -1470,30 +1470,31 @@
 int rightButtonX = portX + portWidth - arrowButtonWidth - 1;
 char buttonText[256];
 Color fillColor = lightGrayIndex();
 labelColor = blackIndex();
 hvGfxNextItemButton(hvg, rightButtonX + NEXT_ITEM_ARROW_BUFFER, y, arrowWidth, arrowWidth,
                     labelColor, fillColor, TRUE);
 hvGfxNextItemButton(hvg, portX + NEXT_ITEM_ARROW_BUFFER, y, arrowWidth, arrowWidth,
                     labelColor, fillColor, FALSE);
 
 safef(buttonText, ArraySize(buttonText), "hgt.prevItem=%s", track->track);
 
 mapBoxReinvoke(hvg, portX, y + 1, arrowButtonWidth, insideHeight, track, FALSE,
                NULL, 0, 0, (revCmplDisp ? "Next item" : "Prev item"), buttonText);
 
 #ifdef IMAGEv2_SHORT_TOGGLE
+// LIKELY UNUSED
 char *label = (theImgBox ? track->longLabel : parentTrack->longLabel);
 int width = portWidth - (2 * arrowButtonWidth);
 int x = portX + arrowButtonWidth;
 // make toggle cover only actual label
 int size = mgFontStringWidth(font,label) + 12;  // get close enough to the label
 if (width > size)
     {
     x += width/2 - size/2;
     width = size;
     }
 mapBoxToggleVis(hvg, x, y + 1, width, insideHeight, (theImgBox ? track : parentTrack));
 #else///ifndef IMAGEv2_SHORT_TOGGLE
 mapBoxToggleVis(hvg, portX + arrowButtonWidth, y + 1, portWidth - (2 * arrowButtonWidth),
                 insideHeight, (theImgBox ? track : parentTrack));
 #endif///ndef IMAGEv2_SHORT_TOGGLE
@@ -10337,17 +10338,24 @@
 
 if (cartOptionalString(cart, "udcTimeout"))
     {
     warn("The Genome Browser cart currently includes the \"udcTimeout\" string. "
 	"While this is useful for debugging hubs, it may negatively impact "
 	"performance.   To clear this variable, click "
 	"<A HREF='hgTracks?hgsid=%s|url|&udcTimeout=[]'>here</A>.",cartSessionId(cart));
     }
 }
 
 void labelTrackAsFiltered(struct track *tg)
 /* add text to track long label to indicate filter is active */
 {
 char *oldLabel = tg->longLabel;
 tg->longLabel = catTwoStrings(oldLabel, " (filter activated)");
+
+struct trackDb *tdbComposite = tdbGetComposite(tg->tdb);
+if (tdbComposite != NULL)
+    {
+    oldLabel = tdbComposite->longLabel;
+    tdbComposite->longLabel = catTwoStrings(oldLabel, " (filter activated)");
+    }
 }