2b21f67e5f67843fc572fde73a555f2c2aee3ed2 fanhsu Sun Jun 12 15:56:44 2011 -0700 Removed commented out code and minor edit of comment for hasOmimPhenotypeClass(). diff --git src/hg/hgTracks/simpleTracks.c src/hg/hgTracks/simpleTracks.c index 392fa0e..c823773 100644 --- src/hg/hgTracks/simpleTracks.c +++ src/hg/hgTracks/simpleTracks.c @@ -10843,32 +10843,32 @@ { dyStringAppend(dy, "; disorder(s): "); dyStringAppend(dy, disorders); } hFreeConn(&conn); return(dy->string); } boolean isOmimOtherClass(char *omimId) /* check if this omimId belongs to the "Others" phenotype class */ /* NOTE: The definition of Others class is kind of tricky. The Other class is defined as: - 2. does not have class 1 or 2 or 3, or 4; some may have class '-1'. - 3. for an entry of omimId that the omimPhenotype table does not even have a row with omimId + 1. does not have class 1 or 2 or 3, or 4; some may have class '-1'. + 2. for an entry of omimId that the omimPhenotype table does not even have a row with omimId */ { boolean result; char answer[255]; struct sqlConnection *conn = hAllocConn(database); char query[256]; safef(query,sizeof(query), "select phenotypeClass from omimPhenotype where omimId =%s and (phenotypeClass=1 or phenotypeClass=2 or phenotypeClass=3 or phenotypeClass=4)", omimId); char *ret = sqlQuickQuery(conn, query, answer, sizeof(answer)); if (ret == NULL) { result = TRUE; } else @@ -11028,39 +11028,30 @@ lighter.b = (6*normal->b + 4*255) / 10; lightest.r = (1*normal->r + 2*255) / 3; lightest.g = (1*normal->g + 2*255) / 3; lightest.b = (1*normal->b + 2*255) / 3; struct sqlConnection *conn = hAllocConn(database); class1Clr = hvGfxFindColorIx(hvg, lightest.r, lightest.g, lightest.b); class2Clr = hvGfxFindColorIx(hvg, lighter.r, lighter.g, lighter.b); class3Clr = hvGfxFindColorIx(hvg, normal->r, normal->g, normal->b); class4Clr = hvGfxFindColorIx(hvg, 105,50,155); classOtherClr = hvGfxFindColorIx(hvg, 190, 190, 190); // light gray -/* last try of Brooke's suggestion, the class 1 and 2 are too bright */ -/* -class1Clr = hvGfxFindColorIx(hvg, 125,225,115); -class2Clr = hvGfxFindColorIx(hvg, 35,155,10); -class3Clr = hvGfxFindColorIx(hvg, 10,60,0); -class4Clr = hvGfxFindColorIx(hvg, 105,50,155); -classOtherClr = hvGfxFindColorIx(hvg, 190, 190, 190); // light gray -*/ - safef(query, sizeof(query), "select omimId, phenotypeClass from omimPhenotype where omimId=%s order by phenotypeClass desc", el->name); sr = sqlMustGetResult(conn, query); row = sqlNextRow(sr); hFreeConn(&conn); if (row == NULL) { // set to gray if this entry does not have any disorder info sqlFreeResult(&sr); return classOtherClr; } else {