From b38324d75ff248ea9c50843e2d6cc4f6911ee8a3 Mon Sep 17 00:00:00 2001 From: Stephen Blott Date: Thu, 14 Sep 2017 13:56:49 +0100 Subject: Revert #2636. Mention @mrmr1993. Mention @gdh1995. We have zoom issues resulting from: - style - zoom - --force-device-scale-factor=1.5 - HiDPI This intended to fix HiDPI, but seems to have created problems in the some of the other cases. I don't have time to figure out the problem right now, so I'm going to revert this and push it as 1.60.2. That leaves us pretty much where we were before, I think, in terms of zoom. We can come back to it later. --- lib/dom_utils.coffee | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'lib') diff --git a/lib/dom_utils.coffee b/lib/dom_utils.coffee index c8ddcedf..d0bd4615 100644 --- a/lib/dom_utils.coffee +++ b/lib/dom_utils.coffee @@ -293,9 +293,7 @@ DomUtils = style = getComputedStyle box if style.position == "static" and not /content|paint|strict/.test(style.contain or "") zoom = +style.zoom || 1 - ratio = window.devicePixelRatio - ratio = 1 if Utils.isFirefox() or not ratio? - top: Math.ceil(window.scrollY * ratio / zoom), left: Math.ceil(window.scrollX * ratio / zoom) + top: Math.ceil(window.scrollY / zoom), left: Math.ceil(window.scrollX / zoom) else rect = box.getBoundingClientRect() top: -rect.top - box.clientTop, left: -rect.left - box.clientLeft -- cgit v1.2.3