diff options
author | portix <portix@gmx.net> | 2013-04-25 00:31:56 +0200 |
---|---|---|
committer | portix <portix@gmx.net> | 2013-04-25 00:31:56 +0200 |
commit | 7b6af8813578537b638732dceb79a4af0fe248df (patch) | |
tree | 4c682113296480f4f542ee486e6d820d836160c9 /scripts/base.js | |
parent | f5da3ab84a0be3a0bb43a22e2a550e767ccfaec5 (diff) | |
download | dwb-7b6af8813578537b638732dceb79a4af0fe248df.zip |
Applying man pages patch, adding hints-offset javascript changes
Diffstat (limited to 'scripts/base.js')
-rw-r--r-- | scripts/base.js | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/scripts/base.js b/scripts/base.js index 8ccffb21..dae765cc 100644 --- a/scripts/base.js +++ b/scripts/base.js @@ -91,8 +91,8 @@ Object.freeze((function () { break; } } - hint.style.top = t + "px"; - hint.style.left = l + "px"; + hint.style.top = (t + globals.hintOffsetTop) + "px"; + hint.style.left = (l + globals.hintOffsetLeft) + "px"; // 37000 is the z-index of the clickble element hint.style.zIndex = 37002; globals.positions.push({top : t, left : l}); @@ -788,7 +788,7 @@ Object.freeze((function () { return null; }; var p_init = function (letter_seq, font, style, - fg_color, bg_color, active_color, normal_color, border, opacity, markHints, autoFollow) + fg_color, bg_color, active_color, normal_color, border, hintOffsetTop, hintOffsetLeft, opacity, markHints, autoFollow) { globals.hintOpacity = opacity; globals.letterSeq = letter_seq; @@ -799,6 +799,8 @@ Object.freeze((function () { globals.activeColor = p_hexToRgb(active_color); globals.normalColor = p_hexToRgb(normal_color); globals.hintBorder = border; + globals.hintOffsetLeft = hintOffsetLeft; + globals.hintOffsetTop = hintOffsetTop; globals.markHints = markHints; globals.autoFollow = autoFollow; globals.bigFont = Math.ceil(font.replace(/\D/g, "") * 1.25) + "px"; @@ -878,7 +880,7 @@ Object.freeze((function () { { p_init(obj.hintLetterSeq, obj.hintFont, obj.hintStyle, obj.hintFgColor, obj.hintBgColor, obj.hintActiveColor, obj.hintNormalColor, - obj.hintBorder, obj.hintOpacity, obj.hintHighlighLinks, obj.hintAutoFollow); + obj.hintBorder, obj.hintOffsetTop, obj.hintOffsetLeft, obj.hintOpacity, obj.hintHighlighLinks, obj.hintAutoFollow); } }; })()); |