Merge pull request #144 from fabrixxm/newacl

fix "resend" function when editor is disabled
This commit is contained in:
Friendika 2011-07-22 05:51:11 -07:00
commit 4e93c742d5

View file

@ -4,7 +4,8 @@
var editor=false;
var textlen = 0;
function initEditor(){
function initEditor(cb){
if (editor==false){
$("#profile-jot-text-loading").show();
tinyMCE.init({
theme : "advanced",
@ -61,18 +62,20 @@ function initEditor(){
ed.pasteAsPlainText = true;
$("#profile-jot-text-loading").hide();
$("#profile-jot-submit-wrapper").show();
if (typeof cb!="undefined") cb();
});
}
});
editor = true;
// setup acl popup
$("#profile-jot-acl-wrapper").hide();
$("a#jot-perms-icon").fancybox({
'transitionIn' : 'none',
'transitionOut' : 'none'
});
} else {
if (typeof cb!="undefined") cb();
}
}
</script>
@ -181,13 +184,18 @@ function initEditor(){
}
}
function jotShare(id) {
$('#like-rotator-' + id).show();
$.get('share/' + id, function(data) {
initEditor(function(){
tinyMCE.execCommand('mceInsertRawHTML',false,data);
$('#like-rotator-' + id).hide();
$(window).scrollTop(0);
});
});
}
function linkdropper(event) {