src/hg/hgTracks/hgTracks.c 1.1629
1.1629 2010/02/17 19:13:53 tdreszer
Dinks to the navigation links, by request
Index: src/hg/hgTracks/hgTracks.c
===================================================================
RCS file: /projects/compbio/cvsroot/kent/src/hg/hgTracks/hgTracks.c,v
retrieving revision 1.1628
retrieving revision 1.1629
diff -b -B -U 4 -r1.1628 -r1.1629
--- src/hg/hgTracks/hgTracks.c 16 Feb 2010 21:15:44 -0000 1.1628
+++ src/hg/hgTracks/hgTracks.c 17 Feb 2010 19:13:53 -0000 1.1629
@@ -4449,40 +4449,33 @@
makeChromIdeoImage(&trackList, psOutput, ideoTn);
#ifdef USE_NAVIGATION_LINKS
hPrintf("<TABLE BORDER=0 CELLPADDING=0 width='%d'><tr style='font-size:small;'>\n",tl.picWidth);//min(tl.picWidth, 800));
- #ifdef IMAGEv2_DRAG_SCROLL
- if(!advancedJavascriptFeaturesEnabled(cart))
- #endif//ndef IMAGEv2_DRAG_SCROLL
- {
hPrintf("<td width='40' align='left'><a href='?hgt.left3=1' title='move 95% to the left'><<<</a>\n");
hPrintf("<td width='30' align='left'><a href='?hgt.left2=1' title='move 47.5% to the left'><<</a>\n");
- hPrintf("<td width='20' align='left'><a href='?hgt.left1=1' title='move 10% to the left'><</a>\n");
- }
+ #ifdef IMAGEv2_DRAG_SCROLL
if(!advancedJavascriptFeaturesEnabled(cart))
- {
-// #ifndef IMAGEv2_DRAG_SCROLL
+ #endif//def IMAGEv2_DRAG_SCROLL
+ hPrintf("<td width='20' align='left'><a href='?hgt.left1=1' title='move 10% to the left'><</a>\n");
+
hPrintf("<td> </td>\n"); // Without 'width=' this cell expand to table with, forcing other cells to the sides.
-// #endif//ndef IMAGEv2_DRAG_SCROLL
hPrintf("<td width='80' align='left'><a href='?hgt.in3=1' title='zoom out 10x'>>>> <<<</a>\n");
hPrintf("<td width='60' align='left'><a href='?hgt.in2=1' title='zoom out 3x'>>> <<</a>\n");
hPrintf("<td width='40' align='left'><a href='?hgt.in1=1' title='zoom out 1.5x'>> <</a>\n");
hPrintf("<td width='40' align='left'><a href='?hgt.inBase=1' title='zoom in to base range'><i>base</i></a>\n");
- }
+
hPrintf("<td> </td>\n"); // Without 'width=' this cell expand to table with, forcing other cells to the sides.
hPrintf("<td width='40' align='right'><a href='?hgt.out1=1' title='zoom out 1.5x'>< ></a>\n");
hPrintf("<td width='60' align='right'><a href='?hgt.out2=1' title='zoom out 3x'><< >></a>\n");
hPrintf("<td width='80' align='right'><a href='?hgt.out3=1' title='zoom out 10x'><<< >>></a>\n");
+ hPrintf("<td> </td>\n"); // Without 'width=' this cell expand to table with, forcing other cells to the sides.
#ifdef IMAGEv2_DRAG_SCROLL
if(!advancedJavascriptFeaturesEnabled(cart))
#endif//ndef IMAGEv2_DRAG_SCROLL
- {
- hPrintf("<td> </td>\n"); // Without 'width=' this cell expand to table with, forcing other cells to the sides.
hPrintf("<td width='20' align='right'><a href='?hgt.right1=1' title='move 10% to the right'>></a>\n");
+
hPrintf("<td width='30' align='right'><a href='?hgt.right2=1' title='move 47.5% to the right'>>></a>\n");
hPrintf("<td width='40' align='right'><a href='?hgt.right3=1' title='move 95% to the right'>>>></a>\n");
- }
- /* use button maker that determines padding, so we can share constants */
hPrintf("</tr></table>\n");
#endif//def USE_NAVIGATION_LINKS
/* Make clickable image and map. */
@@ -4500,16 +4493,21 @@
/* note a trick of WIDTH=27 going on here. The 6,15,6 widths following
* go along with this trick */
hPrintf("<TABLE BORDER=0 CELLSPACING=1 CELLPADDING=1 WIDTH=%d COLS=%d><TR>\n",
tl.picWidth, 27);
-#if !defined(IMAGEv2_DRAG_SCROLL) && !defined(USE_NAVIGATION_LINKS)
- hPrintf("<TD COLSPAN=6 ALIGN=CENTER NOWRAP>");
+ hPrintf("<TD COLSPAN=6 ALIGN=left NOWRAP>");
hPrintf("move start<BR>");
+#ifdef USE_NAVIGATION_LINKS
+ hPrintf("<a href='?hgt.dinkLL=1' title='dink left side to the left'><</a>\n");
+ hTextVar("dinkL", cartUsualString(cart, "dinkL", "2.0"), 3);
+ hPrintf("<a href='?hgt.dinkLR=1' title='dink left side to the right'>></a>\n");
+#else//ifndef USE_NAVIGATION_LINKS
hButton("hgt.dinkLL", " < ");
hTextVar("dinkL", cartUsualString(cart, "dinkL", "2.0"), 3);
hButton("hgt.dinkLR", " > ");
+#endif//ndef USE_NAVIGATION_LINKS
hPrintf("</TD>");
-#endif//ndef !defined(IMAGEv2_DRAG_SCROLL) && !defined(USE_NAVIGATION_LINKS)
+ hPrintf("<td width='30'> </td>\n");
hPrintf("<TD COLSPAN=15 style=\"white-space:normal\">"); // allow this text to wrap
hWrites("Click on a feature for details. ");
hWrites(dragZooming ? "Click or drag in the base position track to zoom in. " : "Click on base position to zoom in around cursor. ");
#ifdef IMAGEv2_DRAG_REORDER
@@ -4520,15 +4518,22 @@
#endif//ndef IMAGEv2_DRAG_REORDER
#ifdef IMAGEv2_DRAG_SCROLL
hWrites("Drag tracks left or right to new position. ");
#endif//def IMAGEv2_DRAG_SCROLL
-#if !defined(IMAGEv2_DRAG_SCROLL) && !defined(USE_NAVIGATION_LINKS)
- hPrintf("</TD><TD COLSPAN=6 ALIGN=CENTER NOWRAP>");
+//#if !defined(IMAGEv2_DRAG_SCROLL) && !defined(USE_NAVIGATION_LINKS)
+ hPrintf("</TD>");
+ hPrintf("<td width='30'> </td>\n");
+ hPrintf("<TD COLSPAN=6 ALIGN=right NOWRAP>");
hPrintf("move end<BR>");
+#ifdef USE_NAVIGATION_LINKS
+ hPrintf("<a href='?hgt.dinkRL=1' title='dink right side to the left'><</a>\n");
+ hTextVar("dinkR", cartUsualString(cart, "dinkR", "2.0"), 3);
+ hPrintf("<a href='?hgt.dinkRR=1' title='dink right side to the right'>></a>\n");
+#else//ifndef USE_NAVIGATION_LINKS
hButton("hgt.dinkRL", " < ");
hTextVar("dinkR", cartUsualString(cart, "dinkR", "2.0"), 3);
hButton("hgt.dinkRR", " > ");
-#endif//ndef !defined(IMAGEv2_DRAG_SCROLL) && !defined(USE_NAVIGATION_LINKS)
+#endif//ndef USE_NAVIGATION_LINKS
hPrintf("</TD></TR></TABLE>\n");
// smallBreak();
/* Display bottom control panel. */