Using page(X|Y)Offset instead of scroll(X|Y)
authorAlexander Ebert <ebert@woltlab.com>
Wed, 27 Jul 2016 10:18:00 +0000 (12:18 +0200)
committerAlexander Ebert <ebert@woltlab.com>
Wed, 27 Jul 2016 10:18:00 +0000 (12:18 +0200)
IE11 doesn't support these and we have to support it :(

Fixes #2065

wcfsetup/install/files/js/WoltLab/WCF/Dom/Util.js

index a28e69776147d1f2dc948679575b3984b473106d..3427d48026793dc74326b016ed47c1272773a5b4 100644 (file)
@@ -154,8 +154,8 @@ define(['Environment', 'StringUtil'], function(Environment, StringUtil) {
                        var rect = el.getBoundingClientRect();
                        
                        return {
-                               top: rect.top + window.scrollY,
-                               left: rect.left + window.scrollX
+                               top: rect.top + window.pageYOffset,
+                               left: rect.left + window.pageXOffset
                        };
                },