src/hg/lib/hui.c 1.239
1.239 2009/09/24 23:00:47 hiram
Eliminate the call to chainDbNormScoreAvailable() and instead use the trackDb variable
Index: src/hg/lib/hui.c
===================================================================
RCS file: /projects/compbio/cvsroot/kent/src/hg/lib/hui.c,v
retrieving revision 1.238
retrieving revision 1.239
diff -b -B -U 4 -r1.238 -r1.239
--- src/hg/lib/hui.c 23 Sep 2009 18:42:20 -0000 1.238
+++ src/hg/lib/hui.c 24 Sep 2009 23:00:47 -0000 1.239
@@ -3821,33 +3821,12 @@
chainFetchColorOption(cart, tdb, compositeLevel);
/* check if we have normalized scores available */
boolean normScoreAvailable = FALSE;
-
-if (! compositeLevel)
- {
- if (chromosome)
- {
- if (chainDbNormScoreAvailable(db, chromosome, tdb->tableName, NULL))
- normScoreAvailable = TRUE;
- }
- else
- {
- // This will not work if tableName is a split table, we don't know
- // the chromosome at this point here
- struct sqlConnection *conn = hAllocConn(db);
- int tblIx = sqlFieldIndex(conn, tdb->tableName, "normScore");
- normScoreAvailable = (tblIx > -1) ? TRUE : FALSE;
- hFreeConn(&conn);
- }
- }
-else
- {
- char * colorOptionType =
+char * normScoreTest =
trackDbSettingClosestToHomeOrDefault(tdb, "chainNormScoreAvailable", "no");
- if (differentWord(colorOptionType, "no"))
+if (differentWord(normScoreTest, "no"))
normScoreAvailable = TRUE;
- }
char optString[256];
if (normScoreAvailable)
{