69e8424f77f7d2513fcf8082aea972d539665540 tdreszer Fri Nov 18 13:14:56 2011 -0800 More touches on BUTTONS_BY_CSS diff --git src/hg/hgTracks/config.c src/hg/hgTracks/config.c index cfb3ef5..bf0393b 100644 --- src/hg/hgTracks/config.c +++ src/hg/hgTracks/config.c @@ -99,32 +99,37 @@ /* check if group section should be displayed */ char *otherState; char *indicator; char *indicatorImg; boolean isOpen = !isCollapsedGroup(group); collapseGroupGoodies(isOpen, FALSE, &indicatorImg, &indicator, &otherState); hPrintf("<TABLE BORDER='1' CELLSPACING='0' style='background-color:#%s; width:54em;'>\n",HG_COL_INSIDE); hPrintf("<TR NOWRAP class='blueToggleBar'>"); hPrintf("<TH NOWRAP align='left' colspan=3>"); hPrintf("<table style='width:100%%;'><tr><td style='text-align:left;'>"); hPrintf("\n<A NAME='%sGroup'></A>",group->name); hPrintf("<input type=hidden name='%s' id='%s' value=%d>", collapseGroupVar(group->name),collapseGroupVar(group->name), (isOpen?0:1)); +#ifdef BUTTONS_BY_CSS + hPrintf("<span class='pmButton toggleButton' onclick=\"vis.toggleForGroup(this,'%s')\" id='%s_button' title='%s this group'>%s</span> ", + group->name, group->name, isOpen?"Collapse":"Expand", indicator); +#else///ifndef BUTTONS_BY_CSS hPrintf("<IMG class='toggleButton' onclick=\"return vis.toggleForGroup(this,'%s');\" id='%s_button' src='%s' alt='%s' title='%s this group'> ", group->name, group->name, indicatorImg, indicator,isOpen?"Collapse":"Expand"); +#endif///ndef BUTTONS_BY_CSS hPrintf("<B> %s</B> ", group->label); hPrintf(" "); hPrintf("</td><td style='text-align:right;'>\n"); hPrintf("<INPUT TYPE=SUBMIT NAME=\"%s\" VALUE=\"%s\" " "onClick=\"document.mainForm.%s.value='%s'; %s\" title='Hide all tracks in this groups'>", configHideAll, "hide all", configGroupTarget, group->name, jsSetVerticalPosition("mainForm")); hPrintf(" "); hPrintf("<INPUT TYPE=SUBMIT NAME=\"%s\" VALUE=\"%s\" " "onClick=\"document.mainForm.%s.value='%s'; %s\" title='Show all tracks in this groups'>", configShowAll, "show all", configGroupTarget, group->name, jsSetVerticalPosition("mainForm")); hPrintf(" "); hPrintf("<INPUT TYPE=SUBMIT NAME=\"%s\" VALUE=\"%s\" " "onClick=\"document.mainForm.%s.value='%s'; %s\" title='Show default tracks in this group'>",