]> source.dussan.org Git - nextcloud-server.git/commitdiff
highlight selected files in the filebrowser
authorRobin Appelman <icewind1991@gmail.com>
Thu, 7 Jul 2011 00:28:57 +0000 (02:28 +0200)
committerRobin Appelman <icewind1991@gmail.com>
Thu, 7 Jul 2011 00:28:57 +0000 (02:28 +0200)
files/css/files.css
files/js/files.js

index 9e0361327db188efcb32a3a536ada3d5e18b4473..a3d098b91161ceb88f637170d542b1fbd85dd4f7 100644 (file)
@@ -76,6 +76,7 @@ table {
 }
 
 tbody tr:hover, tbody tr:active { background-color:#eee; }
+tbody tr.selected { background-color:#ccc; }
 tbody a { color:#000; }
 
 table td.filesize, table td.date
index 2434fceff4334f1d5b51ac8d4044be09ee6b694d..408bd6e48a0a17f881c1be12c8785da38663d4e5 100644 (file)
@@ -31,15 +31,19 @@ $(document).ready(function() {
        
        // Sets the select_all checkbox behaviour :
        $('#select_all').click(function() {
-               if($(this).attr('checked'))
+               if($(this).attr('checked')){
                        // Check all
                        $('td.selection input:checkbox').attr('checked', true);
-               else
+                       $('td.selection input:checkbox').parent().parent().addClass('selected');
+               }else{
                        // Uncheck all
                        $('td.selection input:checkbox').attr('checked', false);
+                       $('td.selection input:checkbox').parent().parent().removeClass('selected');
+               }
        });
        
        $('td.selection input:checkbox').live('click',function() {
+               $(this).parent().parent().toggleClass('selected');
                if(!$(this).attr('checked')){
                        $('#select_all').attr('checked',false);
                }else{