11bc4be74936249529960fb3a532376779debbe5
braney
  Thu Feb 6 11:06:45 2025 -0800
add hgc support for click throughs on quickLifted custom tracks

diff --git src/hg/lib/quickLift.c src/hg/lib/quickLift.c
index 4ffa08e46f5..64ce5872a01 100644
--- src/hg/lib/quickLift.c
+++ src/hg/lib/quickLift.c
@@ -136,31 +136,31 @@
 {
 unsigned ret = 0;
 struct sqlConnection *conn = hConnectCentral();
 char query[2048];
 sqlSafef(query, sizeof(query), "select q.id from quickLiftChain q  where q.fromDb='%s' and q.toDb='%s'", fromDb, toDb);
 char *geneId = sqlQuickString(conn, query);
 
 hDisconnectCentral(&conn);
 
 if (geneId)
     ret = atoi(geneId);
 
 return ret;
 }
 
-struct slList *quickLiftSql(struct sqlConnection *conn, char *quickLiftFile, char *table, char *chrom, int start, int end,  char *query, char *extraWhere, ItemLoader loader, struct hash *chainHash)
+struct slList *quickLiftSql(struct sqlConnection *conn, char *quickLiftFile, char *table, char *chrom, int start, int end,  char *query, char *extraWhere, ItemLoader2 loader, int numFields,struct hash *chainHash)
 // retrieve items for which we have a loader from a SQL database for which we have a set quickLift chains.  
 // Save the chains we used to map the item back to the current reference.
 {
 // need to add some padding to these coordinates
 int padStart = start - 100000;
 if (padStart < 0)
     padStart = 0;
 
 char *linkFileName = getLinkFile(quickLiftFile);
 struct chain *chain, *chainList = chainLoadIdRangeHub(NULL, quickLiftFile, linkFileName, chrom, padStart, end+100000, -1);
 
 struct slList *item, *itemList = NULL;
 int rowOffset = 0;
 struct sqlResult *sr = NULL;
 char **row = NULL;
@@ -185,31 +185,31 @@
             qEnd = cb->qEnd;
         }
 
     if (chain->qStrand == '-')
         qStart = chain->qSize - qStart;
 
     // now grab the items 
     if (query == NULL)
         sr = hRangeQuery(conn, table, chain->qName,
                          qStart, qEnd, extraWhere, &rowOffset);
     else
         sr = sqlGetResult(conn, query);
 
     while ((row = sqlNextRow(sr)) != NULL)
         {
-        item = loader(row + rowOffset);
+        item = loader(row + rowOffset, numFields);
         slAddHead(&itemList, item);
         }
 
     // now squirrel the swapped chains we used to use to make the retrieved items back to us
     chainSwap(chain);
     liftOverAddChainHash(chainHash, chain);
     }
 
 return itemList;
 }
 
 struct bed *quickLiftBeds(struct bed *bedList, struct hash *chainHash, boolean blocked)
 // Map a bed in query coordinates to our current reference
 {
 struct bed *liftedBedList = NULL;