aboutsummaryrefslogtreecommitdiffstats
path: root/vimiumFrontend.js
diff options
context:
space:
mode:
authorYour Name2010-08-27 03:47:10 +0800
committerIlya2010-08-27 08:06:29 +0800
commitfd6174c1e533baf4177549dc6b6f1e3871415abf (patch)
tree52bfe7e2cd9138014c3894f365dde7118f6836d2 /vimiumFrontend.js
parentd711b9e7b79b160efbdf118e201ad2721084b40d (diff)
downloadvimium-fd6174c1e533baf4177549dc6b6f1e3871415abf.tar.bz2
-192 fixed scrollToTop and scrollToBottom default horizontal value now using window.pageXOffset
Diffstat (limited to 'vimiumFrontend.js')
-rw-r--r--vimiumFrontend.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/vimiumFrontend.js b/vimiumFrontend.js
index c33e87db..3d625de9 100644
--- a/vimiumFrontend.js
+++ b/vimiumFrontend.js
@@ -185,8 +185,8 @@ function zoomOut() {
saveZoomLevel(window.location.host, currentZoomLevel);
}
-function scrollToBottom() { window.scrollTo(0, document.body.scrollHeight); }
-function scrollToTop() { window.scrollTo(0, 0); }
+function scrollToBottom() { window.scrollTo(window.pageXOffset, document.body.scrollHeight); }
+function scrollToTop() { window.scrollTo(window.pageXOffset, 0); }
function scrollUp() { window.scrollBy(0, -1 * settings["scrollStepSize"]); }
function scrollDown() { window.scrollBy(0, settings["scrollStepSize"]); }
function scrollPageUp() { window.scrollBy(0, -1 * window.innerHeight / 2); }