7c4930b32e0580573bfc0a8dc37e64e0d49b23db kate Wed May 5 19:54:45 2021 -0700 Code cleanup. refs #27408 diff --git src/hg/hgTables/mainPage.c src/hg/hgTables/mainPage.c index 57037f7..6ad67e9 100644 --- src/hg/hgTables/mainPage.c +++ src/hg/hgTables/mainPage.c @@ -555,78 +555,69 @@ #define HELP_LABEL "Help" static char *stepLabels[] = { "Select dataset", "Define region of interest", "Subset, combine, compare with another track (options)", "Retrieve and display data" }; static char *stepHelp[] = { "Specify the genome, track and data table to be used as the data source.", "Specify whole genome or restrict to a single or set of genomic regions, " "defined by coordinates or identifiers.", -"Press 'create' button and select parameters for desired optional operations", -"Specify output options and press the 'get output' button" +"Press 'create' button and select parameters for desired optional operations.", +"Specify output options and press the 'get output' button." }; static char *stepHelpLinks[] = { "https://genome.ucsc.edu/goldenPath/help/hgTablesHelp.html#GettingStarted", "https://genome.ucsc.edu/goldenPath/help/hgTablesHelp.html#GettingStarted", "https://genome.ucsc.edu/goldenPath/help/hgTablesHelp.html#Filter", "https://genome.ucsc.edu/goldenPath/help/hgTablesHelp.html#OutputFormats" }; static void printStep(int num) /* Print user guidance via steps */ { if (num > STEP_MAX) errAbort("Internal error: table browser help problem"); -hPrintf(""); -hPrintf(""); -hPrintf("
"); -hPrintf("" - "%s" - , stepLabels[num-1]); -hPrintf("%s" - " %s\n", +hPrintf(""); +hPrintf(""); +hPrintf("
"); +hPrintf("%s", + stepLabels[num-1]); +hPrintf("%s %s\n", stepHelp[num-1], stepHelpLinks[num-1], HELP_LABEL); -hPrintf("
"); -hPrintf(""); -hPrintf(""); -} - -static void printStyle() -{ -hPrintf(""); +hPrintf("
"); +hPrintf(""); +hPrintf(""); } void showMainControlTable(struct sqlConnection *conn) /* Put up table with main controls for main page. */ { struct grp *selGroup; boolean isWig = FALSE, isPositional = FALSE, isMaf = FALSE, isBedGr = FALSE, isChromGraphCt = FALSE, isPal = FALSE, isArray = FALSE, isBam = FALSE, isVcf = FALSE, isHalSnake = FALSE, isLongTabix = FALSE, isHic = FALSE; boolean gotClade = hGotClade(); struct hTableInfo *hti = NULL; -printStyle(); hPrintf("\n"); int stepNumber = 1; printStep(stepNumber++); /* Print clade, genome and assembly line. */ { if (gotClade) { hPrintf("\n"); } /* Print table line. */ { hPrintf("
clade:\n"); printCladeListHtml(hGenome(database), "change", onChangeClade()); nbSpaces(3); hPrintf("genome:\n"); printGenomeListForCladeHtml(database, "change", onChangeOrg()); @@ -646,34 +637,32 @@ { hPrintf("
"); selGroup = showGroupField(hgtaGroup, "change", onChangeGroupOrTrack(), conn, hAllowAllTables()); nbSpaces(3); curTrack = showTrackField(selGroup, hgtaTrack, "change", onChangeGroupOrTrack(), FALSE); nbSpaces(3); hPrintf("
"); curTable = showTableField(curTrack, hgtaTable, TRUE); if (isHubTrack(curTable) || (strchr(curTable, '.') == NULL)) /* In same database */ { - hti = getHti(database, curTable, conn); - isPositional = htiIsPositional(hti); - } - isLongTabix = isLongTabixTable( curTable); + hti = getHti(database, curTable, conn); isPositional = htiIsPositional(hti); + } isLongTabix = isLongTabixTable( curTable); isBam = isBamTable(curTable); isHic = isHicTable(curTable); isVcf = isVcfTable(curTable, NULL); isWig = isWiggle(database, curTable); if (isBigWigTable(curTable)) { isPositional = TRUE; isWig = TRUE; } isHalSnake = isHalTable( curTable); isMaf = isMafTable(database, curTrack, curTable); isBedGr = isBedGraph(curTable); isArray = isMicroarray(curTrack, curTable); struct trackDb *tdb = findTdbForTable(database, curTrack, curTable, ctLookupName); isPal = isPalCompatible(conn, tdb, curTable); @@ -1107,22 +1096,22 @@ static char *saveVars[] = { "clade", "org", "db", hgtaGroup, hgtaTrack, hgtaTable, hgtaRegionType, hgtaRange, hgtaOutputType, hgtaOutFileName}; jsCreateHiddenForm(cart, getScriptName(), saveVars, ArraySize(saveVars)); } webNewSection("Using the Table Browser\n"); printMainHelp(); cartFlushHubWarnings(); } void doMainPage(struct sqlConnection *conn) /* Put up the first page user sees. */ { htmlOpen("Table Browser"); -webIncludeResourceFile("jquery-ui.css"); +//webIncludeResourceFile("jquery-ui.css"); mainPageAfterOpen(conn); htmlClose(); }