summaryrefslogtreecommitdiff
path: root/searx/static
diff options
context:
space:
mode:
authorKirill Isakov <ukwt@ya.ru>2016-04-24 21:18:27 +0600
committerKirill Isakov <ukwt@ya.ru>2016-04-24 21:18:27 +0600
commitc12e41a80f7b88e75f6cf5960948c784a316f724 (patch)
tree14461df0367387006530ea9d31fe69a159772c09 /searx/static
parent7b48a663503018dd47b81c94afd9c4df6d62467a (diff)
downloadsearxng-c12e41a80f7b88e75f6cf5960948c784a316f724.tar.gz
searxng-c12e41a80f7b88e75f6cf5960948c784a316f724.zip
Fix result selection for top & bottom scrolling
Diffstat (limited to 'searx/static')
-rw-r--r--searx/static/plugins/js/vim_hotkeys.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/searx/static/plugins/js/vim_hotkeys.js b/searx/static/plugins/js/vim_hotkeys.js
index f7f5989c2..61500d8f5 100644
--- a/searx/static/plugins/js/vim_hotkeys.js
+++ b/searx/static/plugins/js/vim_hotkeys.js
@@ -44,13 +44,13 @@ $(document).ready(function() {
},
71: {
key: 'g',
- fun: scrollPageTo(-document.body.scrollHeight),
+ fun: scrollPageTo(-document.body.scrollHeight, 'top'),
des: 'scroll to the top of the page',
cat: 'Navigation'
},
86: {
key: 'v',
- fun: scrollPageTo(document.body.scrollHeight),
+ fun: scrollPageTo(document.body.scrollHeight, 'bottom'),
des: 'scroll to the bottom of the page',
cat: 'Navigation'
},
@@ -241,10 +241,10 @@ $(document).ready(function() {
}
}
- function scrollPageTo(position) {
+ function scrollPageTo(position, nav) {
return function() {
window.scrollTo(0, position);
- highlightResult('visible')();
+ highlightResult(nav)();
}
}