Fossil SCM
Make the "click to show tooltip" action more "discoverable" with a changing mouse cursor, similar to the timeline nodes. This example uses the "pointer" cursor, but the "help" cursor may also be an option.
Commit
8b8eaad864c55212716d6627bd64f55d4678533c7b105e017f8300ce05b736e4
Parent
b406b41453b00f9…
1 file changed
+5
+5
| --- src/graph.js | ||
| +++ src/graph.js | ||
| @@ -83,10 +83,15 @@ | ||
| 83 | 83 | function TimelineGraph(tx){ |
| 84 | 84 | var topObj = document.getElementById("timelineTable"+tx.iTableId); |
| 85 | 85 | amendCss(tx.circleNodes, tx.showArrowheads); |
| 86 | 86 | topObj.onclick = clickOnGraph |
| 87 | 87 | topObj.ondblclick = dblclickOnGraph |
| 88 | + topObj.onmousemove = function(e) { | |
| 89 | + var ix = findTxIndex(e); | |
| 90 | + var cursor = (ix<0) ? "" : "pointer"; /* Or: cursor = "help"? */ | |
| 91 | + document.getElementsByTagName('body')[0].style.cursor = cursor; | |
| 92 | + }; | |
| 88 | 93 | var canvasDiv; |
| 89 | 94 | var railPitch; |
| 90 | 95 | var mergeOffset; |
| 91 | 96 | var node, arrow, arrowSmall, line, mArrow, mLine, wArrow, wLine; |
| 92 | 97 | |
| 93 | 98 |
| --- src/graph.js | |
| +++ src/graph.js | |
| @@ -83,10 +83,15 @@ | |
| 83 | function TimelineGraph(tx){ |
| 84 | var topObj = document.getElementById("timelineTable"+tx.iTableId); |
| 85 | amendCss(tx.circleNodes, tx.showArrowheads); |
| 86 | topObj.onclick = clickOnGraph |
| 87 | topObj.ondblclick = dblclickOnGraph |
| 88 | var canvasDiv; |
| 89 | var railPitch; |
| 90 | var mergeOffset; |
| 91 | var node, arrow, arrowSmall, line, mArrow, mLine, wArrow, wLine; |
| 92 | |
| 93 |
| --- src/graph.js | |
| +++ src/graph.js | |
| @@ -83,10 +83,15 @@ | |
| 83 | function TimelineGraph(tx){ |
| 84 | var topObj = document.getElementById("timelineTable"+tx.iTableId); |
| 85 | amendCss(tx.circleNodes, tx.showArrowheads); |
| 86 | topObj.onclick = clickOnGraph |
| 87 | topObj.ondblclick = dblclickOnGraph |
| 88 | topObj.onmousemove = function(e) { |
| 89 | var ix = findTxIndex(e); |
| 90 | var cursor = (ix<0) ? "" : "pointer"; /* Or: cursor = "help"? */ |
| 91 | document.getElementsByTagName('body')[0].style.cursor = cursor; |
| 92 | }; |
| 93 | var canvasDiv; |
| 94 | var railPitch; |
| 95 | var mergeOffset; |
| 96 | var node, arrow, arrowSmall, line, mArrow, mLine, wArrow, wLine; |
| 97 | |
| 98 |