From 61e390daf05d9a90be9be051b92b30fb9b40ba09 Mon Sep 17 00:00:00 2001 From: Jeff Becker Date: Sat, 30 Apr 2016 13:32:38 -0400 Subject: [PATCH] add logging --- contrib/js/backlink.js | 5 ++++- contrib/static/nntpchan.js | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/contrib/js/backlink.js b/contrib/js/backlink.js index b5d74d1..a11ebc4 100644 --- a/contrib/js/backlink.js +++ b/contrib/js/backlink.js @@ -264,8 +264,11 @@ function init(prefix) { e.setAttribute("draggable", "true"); e.ondragend = function(ev) { ev.preventDefault(); + var x = 0; + var y = 0; + console.log(ev); var el = document.getElementById("postform_container"); - el.setAttribute("style", "top: "+ev.windowY+"px; left: "+ev.windowX+ "px; position: fixed; "); + el.setAttribute("style", "top: "+y+"px; left: "+x+ "px; position: fixed; "); } } diff --git a/contrib/static/nntpchan.js b/contrib/static/nntpchan.js index 5aac3a9..07e4425 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