30aaa1ec82ebf70d3349ffdd79334c0b0fe64c64 chmalee Wed Oct 4 11:38:32 2023 -0700 Add a class to the icon in hui.c printInfoIcon() so javascript can know to make those tooltips appear, refs #32011 diff --git src/hg/js/utils.js src/hg/js/utils.js index 47f5766..f0d1114 100644 --- src/hg/js/utils.js +++ src/hg/js/utils.js @@ -4100,31 +4100,34 @@ $("[name=ideoMap]>[title],#imgTbl [title]").each(function(i, a) { if (a.title !== undefined && a.title.length > 0) { titleTagToMouseover(a); } }); } function tooltipNodesToMouseover() { /* For server side printed tooltip texts, make them work as pop ups. * Note this assumes two siblings nodes placed next to each other: * <nodeName class="Tooltip">the text or element that is hoverable</nodename> * <nodeName class="Tooltiptext'>the text/html of the popup itself * Please note that the Tooltiptext node can have any arbitrary html in it, like * line breaks or links*/ $(".Tooltip").each(function(i, n) { - addMouseover(n, null, n.nextSibling); + tooltiptext = n.getAttribute("mouseoverText"); + if (tooltiptext !== null) { + addMouseover(n, tooltiptext); + } }); } function parseUrl(url) { // turn a url into some of it's components like server, query-string, etc let protocol, serverName, pathInfo, queryString; let temp; temp = url.split("?"); if (temp.length > 1) queryString = temp.slice(1).join("?"); temp = temp[0].split("/"); protocol = temp[0]; // "https:" serverName = temp[2]; // "genome-test.gi.ucsc.edu" pathInfo = temp.slice(3).join("/"); // "cgi-bin/hgTracks" return {protocol: protocol, serverName: serverName, pathInfo: pathInfo, queryString: queryString};