db1d562564ed1c7a69946edd1aaa8f56e32e69a3
galt
  Mon Oct 15 17:05:46 2012 -0700
bug fix for #9287 - hgc click handler for encode bed plus should handle encode custom track clickthrough properly
diff --git src/hg/hgc/encodeClick.c src/hg/hgc/encodeClick.c
index 679f983..c29bf48 100644
--- src/hg/hgc/encodeClick.c
+++ src/hg/hgc/encodeClick.c
@@ -62,31 +62,31 @@
 int end = cgiInt("t");
 int rowOffset;
 boolean firstTime = TRUE;
 /* connect to DB */
 if (ct)
     {
     db = CUSTOM_TRASH;
     table = ct->dbTableName;
     }
 else
     db = database;
 conn = hAllocConn(db);
 peakType = encodePeakInferTypeFromTable(db, table, tdb->type);
 if (peakType == 0)
     errAbort("unrecognized peak type from table %s", tdb->table);
-genericHeader(tdb, NULL);  // genericClickHandlerPlus gets there first anyway and overrides this which is now moot.
+genericHeader(tdb, NULL);  // genericClickHandlerPlus gets there first anyway (maybe except for encodePeak custom tracks).
 sr = hOrderedRangeQuery(conn, table, chrom, start, end,
 			NULL, &rowOffset);
 while((row = sqlNextRow(sr)) != NULL)
     {
     char **rowPastOffset = row + rowOffset;
     if ((sqlUnsigned(rowPastOffset[1]) != start) ||  (sqlUnsigned(rowPastOffset[2]) != end))
 	continue;
     if (!sameString(rowPastOffset[3], item))
 	continue;
 
     float signal = -1;
     float pValue = -1;
     float qValue = -1;
 
     if (firstTime)