aboutsummaryrefslogtreecommitdiff
path: root/web
diff options
context:
space:
mode:
authorGravatar Ugnich Anton2012-03-06 03:28:19 +0700
committerGravatar Ugnich Anton2012-03-06 03:28:19 +0700
commit4441c908f773f1b7c2b203fc6f47349408ae82c0 (patch)
treed502bb7f73cdab4c493395248dc3da812984aef1 /web
parentb4a7601a14c9077fcfefc083ed39348409d57b76 (diff)
UserThread unfoldReply
Diffstat (limited to 'web')
-rw-r--r--web/scripts3.js13
1 files changed, 12 insertions, 1 deletions
diff --git a/web/scripts3.js b/web/scripts3.js
index f6e9cdef..bf3da76f 100644
--- a/web/scripts3.js
+++ b/web/scripts3.js
@@ -41,7 +41,7 @@ function showCommentForm(mid,rid) {
c.before('<input type="hidden" name="mid" value="'+mid+'"/><input type="hidden" name="rid" value="'+rid+'"/>');
c.append('<textarea name="body" rows="1" class="reply" placeholder="Add a comment..." onkeypress="postformListener(this.form,event)"></textarea><input type="submit" value="OK"/>');
}
-// $('#replies #'+rid+' .msg-links').hide();
+ // $('#replies #'+rid+' .msg-links').hide();
$('#replies #'+rid+' .msg-comment').show();
$('#replies #'+rid+' textarea')[0].focus();
$('#replies #'+rid+' textarea').autoResize({
@@ -51,6 +51,17 @@ function showCommentForm(mid,rid) {
return false;
}
+function unfoldReply() {
+ if((0+window.location.hash.substring(1))>0) {
+ var el=$(window.location.hash);
+ while(el.is(":hidden")) {
+ el=el.prev();
+ }
+ showMoreReplies(el.attr('id'));
+ window.location.replace(window.location.hash);
+ }
+}
+
$(document).ready(function() {
$('textarea.reply').autoResize({
extraSpace: 0,