482e17639372073c44c32d26707a69b8132b3ba4 braney Fri Aug 5 18:05:55 2011 -0700 changes related to #4842 diff --git src/hg/hgTracks/config.c src/hg/hgTracks/config.c index 5f7d524..f7367b5 100644 --- src/hg/hgTracks/config.c +++ src/hg/hgTracks/config.c @@ -2,30 +2,31 @@ #include "common.h" #include "dystring.h" #include "cheapcgi.h" #include "htmshell.h" #include "hdb.h" #include "hCommon.h" #include "cart.h" #include "web.h" #include "customTrack.h" #include "hgTracks.h" #include "hgConfig.h" #include "jsHelper.h" #include "imageV2.h" #include "search.h" +#include "hubConnect.h" #define DOWNLOADS_ONLY_TRACKS_INCLUDED #ifdef DOWNLOADS_ONLY_TRACKS_INCLUDED #include "fileUi.h" #endif///def DOWNLOADS_ONLY_TRACKS_INCLUDED static void textSizeDropDown() /* Create drop down for font size. */ { static char *sizes[] = {"6", "8", "10", "12", "14", "18", "24", "34"}; hDropList(textSizeVar, sizes, ArraySize(sizes), tl.textSize); } #ifdef PRIORITY_CHANGES_IN_CONFIG_UI static void printGroupListHtml(char *groupCgiName, struct group *groupList, char *defaultGroup) @@ -77,31 +78,30 @@ if (changeVis != -2) { if (groupTarget == NULL || (groupList != NULL && sameString(groupTarget, groupList->name))) { if (changeVis == -1) rulerMode = tvFull; else rulerMode = changeVis; } } #endif /* BOB_DOESNT_LIKE */ jsInit(); cgiMakeHiddenVar(configGroupTarget, "none"); -boolean isFirstNotCtGroup = TRUE; for (group = groupList; group != NULL; group = group->next) { struct trackRef *tr; if (group->trackList == NULL) continue; /* check if group section should be displayed */ char *otherState; char *indicator; char *indicatorImg; boolean isOpen = !isCollapsedGroup(group); collapseGroupGoodies(isOpen, FALSE, &indicatorImg, &indicator, &otherState); hPrintf("\n",HG_COL_INSIDE); @@ -150,61 +150,59 @@ hPrintf("\n"); #ifdef PRIORITY_CHANGES_IN_CONFIG_UI if (withPriorityOverride) { hPrintf("\n"); if (isOpen) hPrintf(" ", wrapWhiteFont("Group")); hPrintf("\n"); } #endif///def PRIORITY_CHANGES_IN_CONFIG_UI hPrintf("\n"); - /* First non-CT group gets ruler. */ - if (!showedRuler && isFirstNotCtGroup && + /* First non-CT, non-hub group gets ruler. */ + if (!showedRuler && !isHubTrack(group->name) && differentString(group->name, "user")) { showedRuler = TRUE; hPrintf("",(isOpen ? "" : "style='display: none'"), group->name); hPrintf(""); hPrintf(""); hPrintf(""); #ifdef PRIORITY_CHANGES_IN_CONFIG_UI if (withPriorityOverride) { hPrintf(""); hPrintf(""); } #endif///def PRIORITY_CHANGES_IN_CONFIG_UI hPrintf("\n"); } - if (differentString(group->name, "user")) - isFirstNotCtGroup = FALSE; /* Scan track list to determine which supertracks have visible member * tracks, and to insert a track in the list for the supertrack. * Sort tracks and supertracks together by priority */ makeGlobalTrackHash(trackList); groupTrackListAddSuper(cart, group); if (!withPriorityOverride) { /* sort hierarchically by priority, considering supertracks */ struct trackRef *refList = NULL, *ref; for (tr = group->trackList; tr != NULL; tr = tr->next) { struct track *track = tr->track; if (tdbIsSuperTrackChild(track->tdb)) /* ignore supertrack member tracks till supertrack is found */
\n"); safef(pname, sizeof(pname), "%s.priority",group->name); hDoubleVar(pname, (double)group->priority, 4); hPrintf(" %s
"); hPrintf("", hgTrackUiName(), cartSessionVarName(), cartSessionId(cart), chromName, RULER_TRACK_NAME); hPrintf("%s", RULER_TRACK_LABEL); hPrintf(""); hTvDropDownClass("ruler", rulerMode, FALSE, rulerMode ? "normalText" : "hiddenText"); hPrintf(""); hPrintf("Chromosome position in bases. (Clicks here zoom in 3x)"); hPrintf(""); hPrintf(""); hPrintf("