aboutsummaryrefslogtreecommitdiffstats
path: root/view/js/main.js
diff options
context:
space:
mode:
authorRedMatrix <info@friendica.com>2014-05-21 06:44:53 +1000
committerRedMatrix <info@friendica.com>2014-05-21 06:44:53 +1000
commit8333f9fe20b6190e48a9d802baaf41d2926545ed (patch)
tree76299b17394d36f546d0533c9fe889a2e920d9a2 /view/js/main.js
parent6d01707a724504a34b8e84e87c6601a046de9739 (diff)
parent1aa7f3136f336a66220aae28f1404e2e2a4ecd39 (diff)
downloadvolse-hubzilla-8333f9fe20b6190e48a9d802baaf41d2926545ed.tar.gz
volse-hubzilla-8333f9fe20b6190e48a9d802baaf41d2926545ed.tar.bz2
volse-hubzilla-8333f9fe20b6190e48a9d802baaf41d2926545ed.zip
Merge pull request #463 from git-marijus/master
some work on comment_item.tpl
Diffstat (limited to 'view/js/main.js')
-rw-r--r--view/js/main.js30
1 files changed, 17 insertions, 13 deletions
diff --git a/view/js/main.js b/view/js/main.js
index fa32df424..b388ab940 100644
--- a/view/js/main.js
+++ b/view/js/main.js
@@ -6,21 +6,25 @@
$("#comment-edit-text-" + id).addClass("comment-edit-text-full");
$("#comment-edit-text-" + id).removeClass("comment-edit-text-empty");
$("#mod-cmnt-wrap-" + id).show();
- openMenu("comment-edit-submit-wrapper-" + id);
+ openMenu("comment-tools-" + id);
return true;
}
return false;
}
+
function commentClose(obj,id) {
- if(obj.value == '') {
- obj.value = aStr['comment'];
- $("#comment-edit-text-" + id).removeClass("comment-edit-text-full");
- $("#comment-edit-text-" + id).addClass("comment-edit-text-empty");
- $("#mod-cmnt-wrap-" + id).hide();
- closeMenu("comment-edit-submit-wrapper-" + id);
- return true;
- }
- return false;
+ //$(document).on('click', function() {
+ if(obj.value == '') {
+ obj.value = aStr['comment'];
+ $("#comment-edit-text-" + id).removeClass("comment-edit-text-full");
+ $("#comment-edit-text-" + id).addClass("comment-edit-text-empty");
+ $("#mod-cmnt-wrap-" + id).hide();
+ closeMenu("comment-tools-" + id);
+ return true;
+ }
+ return false;
+ //});
+
}
function showHideCommentBox(id) {
@@ -32,14 +36,13 @@
}
}
-
function commentInsert(obj,id) {
var tmpStr = $("#comment-edit-text-" + id).val();
if(tmpStr == '$comment') {
tmpStr = '';
$("#comment-edit-text-" + id).addClass("comment-edit-text-full");
$("#comment-edit-text-" + id).removeClass("comment-edit-text-empty");
- openMenu("comment-edit-submit-wrapper-" + id);
+ openMenu("comment-tools-" + id);
}
var ins = $(obj).html();
ins = ins.replace('&lt;','<');
@@ -62,7 +65,7 @@
tmpStr = "";
$("#comment-edit-text-" + id).addClass("comment-edit-text-full");
$("#comment-edit-text-" + id).removeClass("comment-edit-text-empty");
- openMenu("comment-edit-submit-wrapper-" + id);
+ openMenu("comment-tools-" + id);
$("#comment-edit-text-" + id).val(tmpStr);
}
@@ -748,6 +751,7 @@ function updateConvItems(mode,data) {
$("#comment-edit-form-" + id).serialize(),
function(data) {
if(data.success) {
+ $("#comment-edit-preview-" + id).hide();
$("#comment-edit-wrapper-" + id).hide();
$("#comment-edit-text-" + id).val('');
var tarea = document.getElementById("comment-edit-text-" + id);