]> git.mxchange.org Git - friendica.git/blobdiff - view/theme/quattro/theme.php
Merge pull request #1149 from fabrixxm/quattro_fixs
[friendica.git] / view / theme / quattro / theme.php
index 167ebc75383f1e86c13349f38c4a773273da13b5..1be5c02678ff7a2784aabf0e7b49c1c428c807a0 100644 (file)
@@ -42,6 +42,24 @@ $(document).ready(function(){
                }
                
     });
+       
+       /* 
+        * show and hide contact action buttons in 
+        * contacts page on contacts' checkbox selection
+        */
+       $('.contact-select').bind('click', function(e) {
+               var y = e.clientY;
+               var elm = $("#contacts-actions");
+               y=y-40;
+               if (y<0) y=0;
+               if (y+elm.height() > $("html").height()) y=$("html").height()-elm.height();
+               elm.css('top', y+"px");
+               if ($(".contact-select:checked").length > 0) {
+                       elm.show();
+               } else {
+                       elm.hide();
+               }
+       });
 });        
 
 function insertFormatting(comment,BBcode,id) {
@@ -90,43 +108,44 @@ function cmtBbOpen(id) {
 function cmtBbClose(id) {
        $("#comment-edit-bb-" + id).hide();
 }
-$(document).ready(function() {
-
-$('html').click(function() { $("#nav-notifications-menu" ).hide(); });
-
-$('.group-edit-icon').hover(
-       function() {
-               $(this).addClass('icon'); $(this).removeClass('iconspacer');},
-       function() {
-               $(this).removeClass('icon'); $(this).addClass('iconspacer');}
-       );
 
-$('.sidebar-group-element').hover(
-       function() {
-               id = $(this).attr('id');
-               $('#edit-' + id).addClass('icon'); $('#edit-' + id).removeClass('iconspacer');},
-
-       function() {
-               id = $(this).attr('id');
-               $('#edit-' + id).removeClass('icon');$('#edit-' + id).addClass('iconspacer');}
-       );
-
-
-$('.savedsearchdrop').hover(
-       function() {
-               $(this).addClass('drop'); $(this).addClass('icon'); $(this).removeClass('iconspacer');},
-       function() {
-               $(this).removeClass('drop'); $(this).removeClass('icon'); $(this).addClass('iconspacer');}
-       );
-
-$('.savedsearchterm').hover(
-       function() {
-               id = $(this).attr('id');
-               $('#drop-' + id).addClass('icon');      $('#drop-' + id).addClass('drophide'); $('#drop-' + id).removeClass('iconspacer');},
+$(document).ready(function() {
 
-       function() {
-               id = $(this).attr('id');
-               $('#drop-' + id).removeClass('icon');$('#drop-' + id).removeClass('drophide'); $('#drop-' + id).addClass('iconspacer');}
+       $('html').click(function() { $("#nav-notifications-menu" ).hide(); });
+
+       $('.group-edit-icon').hover(
+               function() {
+                       $(this).addClass('icon'); $(this).removeClass('iconspacer');},
+               function() {
+                       $(this).removeClass('icon'); $(this).addClass('iconspacer');}
+               );
+
+       $('.sidebar-group-element').hover(
+               function() {
+                       id = $(this).attr('id');
+                       $('#edit-' + id).addClass('icon'); $('#edit-' + id).removeClass('iconspacer');},
+
+               function() {
+                       id = $(this).attr('id');
+                       $('#edit-' + id).removeClass('icon');$('#edit-' + id).addClass('iconspacer');}
+               );
+
+
+       $('.savedsearchdrop').hover(
+               function() {
+                       $(this).addClass('drop'); $(this).addClass('icon'); $(this).removeClass('iconspacer');},
+               function() {
+                       $(this).removeClass('drop'); $(this).removeClass('icon'); $(this).addClass('iconspacer');}
+               );
+
+       $('.savedsearchterm').hover(
+               function() {
+                       id = $(this).attr('id');
+                       $('#drop-' + id).addClass('icon');      $('#drop-' + id).addClass('drophide'); $('#drop-' + id).removeClass('iconspacer');},
+
+               function() {
+                       id = $(this).attr('id');
+                       $('#drop-' + id).removeClass('icon');$('#drop-' + id).removeClass('drophide'); $('#drop-' + id).addClass('iconspacer');}
        );
 
 });