diff --git a/contrib/js/reply.js b/contrib/js/reply.js index 0b82240..0e10977 100644 --- a/contrib/js/reply.js +++ b/contrib/js/reply.js @@ -154,6 +154,8 @@ DynReply.prototype.moveTo = function(x,y) { this.y = y; console.log(this.x, this.y); } + } else { + console.log("!!", x, y); } } @@ -390,6 +392,7 @@ function init(prefix) { console.log(ox, oy, dx, dy); rpl.translate(dx, dy); + console.log(rpl.x, rpl.y); ox = rpl.x; oy = rpl.y; }, false); diff --git a/contrib/static/nntpchan.js b/contrib/static/nntpchan.js index 635fe1d..1167eee 100644 --- a/contrib/static/nntpchan.js +++ b/contrib/static/nntpchan.js @@ -54,7 +54,7 @@ var elem=document.createElement("div");elem.setAttribute("id","postform_containe elem=document.createElement("input");elem.setAttribute("name","subject");elem.setAttribute("value","");elem.setAttribute("id","postform_subject");var submit=document.createElement("input");submit.setAttribute("value","reply");submit.setAttribute("class","button");submit.setAttribute("type","submit");submit.setAttribute("id","postform_submit");table_insert_row(tbody,document.createTextNode("Subject"),[elem,submit]);elem=document.createElement("textarea");elem.setAttribute("id","postform_message");elem.setAttribute("name","message");elem.setAttribute("cols","40");elem.setAttribute("rows","5");table_insert_row(tbody,document.createTextNode("Comment"),[elem]);elem=document.createElement("input");elem.setAttribute("class","postform_attachment");elem.setAttribute("id","postform_attachments");elem.setAttribute("type","file");elem.setAttribute("name","attachment_uploaded");elem.setAttribute("multiple","multiple");table_insert_row(tbody,document.createTextNode("Files"),[elem]);elem=document.createElement("input");elem.setAttribute("type","checkbox");elem.setAttribute("name","dubs");table_insert_row(tbody,document.createTextNode("Get Dubs"),[elem]);elem=document.createElement("img");elem.setAttribute("id","captcha_img");elem.alt="captcha";table_insert_row(tbody,document.createTextNode("Captcha"),[elem]);elem=document.createElement("input");elem.name="captcha";elem.autocomplete="off";elem.setAttribute("id","captcha_solution");table_insert_row(tbody,document.createTextNode("Solution"),[elem]) table.appendChild(tbody);this.form.appendChild(table);this.elem.appendChild(this.form);document.body.appendChild(this.elem);this.board=null;this.roothash=null;this.prefix=null;this.url=null;} DynReply.prototype.translate=function(dx,dy){var x=this.x+dx;var y=this.y+dy;this.moveTo(x,y);} -DynReply.prototype.moveTo=function(x,y){if(x&&y){var nx=document.body.clientLeft-x;if(nx>0&&y>0&&nx0&&y>0&&nx