31b5609343b1ad1864cc9ce43ddbf7bad3435208
angie
Mon Jan 17 10:06:44 2011 -0800
Just for fun, added HGDP world map icon to collapsible section header in SNP details.
diff --git src/hg/hgc/hgc.c src/hg/hgc/hgc.c
index 0946571..d77f9b2 100644
--- src/hg/hgc/hgc.c
+++ src/hg/hgc/hgc.c
@@ -15998,32 +15998,35 @@
{
char *hgdpGeoTable = "hgdpGeo"; // make this a trackDb setting
if (!hTableExists(database, hgdpGeoTable))
return;
struct sqlResult *sr;
char **row;
char query[512];
safef(query, sizeof(query),
"select * from %s where name = '%s' and chrom = '%s' and chromStart = %d",
hgdpGeoTable, itemName, seqName, start);
sr = sqlGetResult(conn, query);
if ((row = sqlNextRow(sr)) != NULL)
{
struct hgdpGeo geo;
hgdpGeoStaticLoad(row+1, &geo);
- jsBeginCollapsibleSection(cart, tdb->track, "hgdpGeo", "Human Genome Diversity Project SNP",
- FALSE);
+ char title[1024];
+ safef(title, sizeof(title), "Human Genome Diversity Project SNP"
+ "",
+ hgdpPngFilePath(itemName));
+ jsBeginCollapsibleSection(cart, tdb->track, "hgdpGeo", title, FALSE);
printf("Note: These annotations are taken directly from the "
"HGDP Selection Browser, "
"and may indicate the allele on the opposite strand from that given above.
\n");
printf("Ancestral Allele: %c
\n", geo.ancestralAllele);
printf("Derived Allele: %c
\n", geo.derivedAllele);
printf("
\n"); hgdpGeoFreqTable(&geo); printf(" | \n"); hgdpGeoImg(&geo); printf(" |