]> git.mxchange.org Git - friendica.git/blobdiff - view/theme/slackr/theme.php
Merge branch 'develop' of github.com:annando/friendica into 1409-shadow-items
[friendica.git] / view / theme / slackr / theme.php
index a5520fce5f03f3320248676d9aacefffc76ad5b3..43deb4b8ccebe8590751f5abd749f9e5b3e19c21 100644 (file)
@@ -1,9 +1,11 @@
 <?php
+
+function slackr_init(&$a) {
 $a->theme_info = array(
   'extends' => 'duepuntozero',
 );
+set_template_engine($a, 'smarty3');
 
-function slackr_init(&$a) {
 $a->page['htmlhead'] .= <<< EOT
 <script>
 function insertFormatting(comment,BBcode,id) {
@@ -14,7 +16,9 @@ function insertFormatting(comment,BBcode,id) {
                        $("#comment-edit-text-" + id).addClass("comment-edit-text-full");
                        $("#comment-edit-text-" + id).removeClass("comment-edit-text-empty");
                        openMenu("comment-edit-submit-wrapper-" + id);
-                                                               }
+                       $("#comment-edit-text-" + id).val(tmpStr);
+
+               }
 
        textarea = document.getElementById("comment-edit-text-" +id);
        if (document.selection) {
@@ -35,14 +39,32 @@ function insertFormatting(comment,BBcode,id) {
        return true;
 }
 
-function cmtBbOpen(id) {
-       $(".comment-edit-bb-" + id).show();
+function cmtBbOpen(comment, id) {
+       if($(comment).hasClass('comment-edit-text-full')) {
+               $(".comment-edit-bb-" + id).show();
+               return true;
+       }
+       return false;
 }
-function cmtBbClose(id) {
-       $(".comment-edit-bb-" + id).hide();
+function cmtBbClose(comment, id) {
+//     if($(comment).hasClass('comment-edit-text-empty')) {
+//             $(".comment-edit-bb-" + id).hide();
+//             return true;
+//     }
+       return false;
 }
+
+
+function hidecal() {
+       if(editor) return;
+       $('.fc').hide();
+}
+
 $(document).ready(function() {
 
+       $("#profile-jot-text").focus(hidecal);
+       $("#profile-jot-text").click(hidecal);
+
 $('html').click(function() { $("#nav-notifications-menu" ).hide(); });
 
 $('.group-edit-icon').hover(
@@ -85,4 +107,4 @@ $('.savedsearchterm').hover(
 
 </script>
 EOT;
-}
\ No newline at end of file
+}