7bc24686024ec14d351ab208b5179ab251d7c463 tdreszer Fri Oct 14 16:34:15 2011 -0700 Major work on bedFilt, psl and wigMaf to make them properly composite ready. diff --git src/hg/lib/hgMaf.c src/hg/lib/hgMaf.c index f29b972..af1a023 100644 --- src/hg/lib/hgMaf.c +++ src/hg/lib/hgMaf.c @@ -408,35 +408,35 @@ wigTable = fields[i]; if (hTableExists(db, wigTable)); { AllocVar(wig); wig->table = cloneString(wigTable); wigLabel = (i+1 == fieldCt ? DEFAULT_CONS_LABEL : fields[i+1]); wig->leftLabel = cloneString(wigLabel); wigLabel = (i+2 >= fieldCt ? wig->leftLabel : fields[i+2]); wig->uiLabel = cloneString(wigLabel); slAddTail(&wigList, wig); } } return wigList; } -char *wigMafWiggleVar(struct trackDb *tdb, struct consWiggle *wig) +char *wigMafWiggleVar(char *prefix, struct consWiggle *wig) /* Return name of cart variable for this cons wiggle */ { char option[128]; -safef(option, sizeof option, "%s.cons.%s", tdb->track, wig->leftLabel); +safef(option, sizeof option, "%s.cons.%s", prefix, wig->leftLabel); return (cloneString(option)); } struct consWiggle *consWiggleFind(char *db,struct trackDb *parent,char *table) /* Return conservation wig if it is found in the parent. */ { if(parent == NULL || !startsWith("wigMaf", parent->type)) return NULL; struct consWiggle *wig, *wiggles = wigMafWiggles(db, parent); for (wig = wiggles; wig != NULL && differentString(wig->table,table); wig = wig->next) {} return wig; }