From 4264004eafd303b68e0f570d9d890e9b0f0b71f0 Mon Sep 17 00:00:00 2001 From: Jeff Becker Date: Sat, 30 Apr 2016 13:31:57 -0400 Subject: [PATCH] fix x,y --- contrib/js/backlink.js | 2 +- contrib/static/nntpchan.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/contrib/js/backlink.js b/contrib/js/backlink.js index dcf3f5d..b5d74d1 100644 --- a/contrib/js/backlink.js +++ b/contrib/js/backlink.js @@ -265,7 +265,7 @@ function init(prefix) { e.ondragend = function(ev) { ev.preventDefault(); var el = document.getElementById("postform_container"); - el.setAttribute("style", "top: "+ev.y+"px; left: "+ev.x+ "px; position: fixed; "); + el.setAttribute("style", "top: "+ev.windowY+"px; left: "+ev.windowX+ "px; position: fixed; "); } } diff --git a/contrib/static/nntpchan.js b/contrib/static/nntpchan.js index f8ca398..5aac3a9 100644 --- a/contrib/static/nntpchan.js +++ b/contrib/static/nntpchan.js @@ -37,7 +37,7 @@ parent.appendChild(wrapper);parent.backlink=false;},function(msg){var wrapper=do parent.backlink=true;}};parent.backlink=true;} function inject_hover_for_element(elem){var elems=elem.getElementsByClassName("backlink");var ls=[];var l=elems.length;for(var idx=0;idx