From 325e8b8e3b31ae2a7379f32e657bdade8a2efe0d Mon Sep 17 00:00:00 2001 From: nazri Date: Wed, 13 Apr 2011 16:35:32 +0800 Subject: Make link hints appear out of order This has the effect of link hints 'spreading' out after the first key is pressed on a link-heavy page. --- linkHints.js | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'linkHints.js') diff --git a/linkHints.js b/linkHints.js index e3ecacfb..f4ffc768 100644 --- a/linkHints.js +++ b/linkHints.js @@ -369,6 +369,12 @@ var alphabetHints = { var hintStringLength = hintString.length; for (var i = 0; i < numHintDigits - hintStringLength; i++) hintString.unshift(settings.get('linkHintCharacters')[0]); + + // Reversing the hint string has the advantage of making the link hints + // appear to spread out after the first key is hit. This is helpful on a + // page that has http links that are close to each other where link hints + // of 2 characters or more occlude each other. + hintString.reverse(); return hintString.join(""); }, -- cgit v1.2.3