|
@ -83,7 +83,6 @@ function textarea_onkey(ev) |
|
|
|
|
|
|
|
|
//hide comment form
|
|
|
//hide comment form
|
|
|
function close_commform() { |
|
|
function close_commform() { |
|
|
|
|
|
|
|
|
var formdiv = document.getElementById('commform-div'); |
|
|
var formdiv = document.getElementById('commform-div'); |
|
|
if( formdiv == null ) { |
|
|
if( formdiv == null ) { |
|
|
alert("form null"); |
|
|
alert("form null"); |
|
@ -116,9 +115,8 @@ function img_click(element, ev) { |
|
|
// show comment form, when 'edit' or 'comment' button pressed
|
|
|
// show comment form, when 'edit' or 'comment' button pressed
|
|
|
function box_edit(button, action) |
|
|
function box_edit(button, action) |
|
|
{ |
|
|
{ |
|
|
var divbox = button.parentNode.parentNode.parentNode.parentNode; |
|
|
var divbox = button.parentNode.parentNode.parentNode; |
|
|
var id = divbox.id; |
|
|
var id = divbox.id; |
|
|
//alert("id: " + id);
|
|
|
|
|
|
var divpointer = document.getElementById(divbox.id + '-pointer'); |
|
|
var divpointer = document.getElementById(divbox.id + '-pointer'); |
|
|
|
|
|
|
|
|
var text; |
|
|
var text; |
|
@ -135,21 +133,19 @@ function box_edit(button, action) |
|
|
//alert('not yet 2:' + text + text_el); // + divpointer.style.top "x" + divpo );
|
|
|
//alert('not yet 2:' + text + text_el); // + divpointer.style.top "x" + divpo );
|
|
|
id = id.substring(2); |
|
|
id = id.substring(2); |
|
|
return show_form(divbox.img_id, dx, dy, id, text, action); |
|
|
return show_form(divbox.img_id, dx, dy, id, text, action); |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
// show comment form when 'update-comment' button pressed
|
|
|
// show comment form when 'update-comment' button pressed
|
|
|
function update_comment(button) |
|
|
function update_comment(button) |
|
|
{ |
|
|
{ |
|
|
var divbox = button.parentNode.parentNode.parentNode; |
|
|
var divbox = button.parentNode.parentNode.parentNode.parentNode; |
|
|
var id = divbox.id; |
|
|
var id = divbox.id; |
|
|
var divpointer = document.getElementById(divbox.id + '-pointer'); |
|
|
var divpointer = document.getElementById(divbox.id + '-pointer'); |
|
|
var dx = parseInt(divpointer.style.left); |
|
|
var dx = parseInt(divpointer.style.left); |
|
|
var dy = parseInt(divpointer.style.top); |
|
|
var dy = parseInt(divpointer.style.top); |
|
|
|
|
|
|
|
|
var commentdiv = button.parentNode.parentNode; |
|
|
var commentdiv = button.parentNode.parentNode.parentNode; |
|
|
var id = commentdiv.id.substring(1); |
|
|
var id = commentdiv.id.substring(1); |
|
|
|
|
|
|
|
|
var text = document.getElementById('kt' + id).innerHTML.unescapeHTML(); |
|
|
var text = document.getElementById('kt' + id).innerHTML.unescapeHTML(); |
|
|
|
|
|
|
|
|
return show_form(divbox.img_id, dx, dy, id, text, 'update-comment'); |
|
|
return show_form(divbox.img_id, dx, dy, id, text, 'update-comment'); |
|
@ -202,8 +198,6 @@ function box_onmouseover(box, done) |
|
|
var id = box.id; |
|
|
var id = box.id; |
|
|
var pointer = document.getElementById(box.id + '-pointer'); |
|
|
var pointer = document.getElementById(box.id + '-pointer'); |
|
|
pointer.className = done ? 'pointer-done-hi' : 'pointer-hi'; |
|
|
pointer.className = done ? 'pointer-done-hi' : 'pointer-hi'; |
|
|
//console.log('mouseout');
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
function box_onmouseout(box, done) |
|
|
function box_onmouseout(box, done) |
|
@ -211,8 +205,6 @@ function box_onmouseout(box, done) |
|
|
var id = box.id; |
|
|
var id = box.id; |
|
|
var pointer = document.getElementById(box.id + '-pointer'); |
|
|
var pointer = document.getElementById(box.id + '-pointer'); |
|
|
pointer.className = done ? 'pointer-done' : 'pointer'; |
|
|
pointer.className = done ? 'pointer-done' : 'pointer'; |
|
|
|
|
|
|
|
|
//console.log('mousein');
|
|
|
|
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
function save_scroll(form) |
|
|
function save_scroll(form) |
|
@ -220,8 +212,6 @@ function save_scroll(form) |
|
|
//alert('save_scroll:' + document.body.scrollTop);
|
|
|
//alert('save_scroll:' + document.body.scrollTop);
|
|
|
form.scroll.value = document.body.scrollTop; |
|
|
form.scroll.value = document.body.scrollTop; |
|
|
//alert('save_scroll:' + form.scroll.value);
|
|
|
//alert('save_scroll:' + form.scroll.value);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return true; |
|
|
return true; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|