]> git.wh0rd.org Git - tt-rss.git/commitdiff
add dropout effect when hiding read feeds
authorAndrew Dolgov <fox@bah.spb.su>
Fri, 10 Aug 2007 09:52:24 +0000 (10:52 +0100)
committerAndrew Dolgov <fox@bah.spb.su>
Fri, 10 Aug 2007 09:52:24 +0000 (10:52 +0100)
feedlist.js
functions.js
functions.php

index c0257fd91bb9eb21294cd11e5912bc86b6a626b0..8c0420d0ea94b5c3fa10b98e8ac8dfb252682849 100644 (file)
@@ -193,7 +193,7 @@ function toggleCollapseCat(cat) {
                var cat_list = document.getElementById("FCATLIST-" + cat).parentNode;
                var caption = document.getElementById("FCAP-" + cat);
                
-               if (cat_list.className.match("invisible")) {
+/*             if (cat_list.className.match("invisible")) {
                        cat_list.className = "";
                        caption.innerHTML = caption.innerHTML.replace("...", "");
                        if (cat == 0) {
@@ -204,8 +204,11 @@ function toggleCollapseCat(cat) {
                        caption.innerHTML = caption.innerHTML + "...";
                        if (cat == 0) {
                                setCookie("ttrss_vf_uclps", "1");
-                       }
-               }
+                       } 
+
+               } */
+
+               Effect.toggle('FCATLIST-' + cat, 'blind', { duration: 0.5 });
 
                new Ajax.Request("backend.php?op=feeds&subop=collapse&cid=" + 
                        param_escape(cat));
index c6ef5fba99f9829c3a2d90fd2e43a6645f9e5317..56e56b1a1dbf9e1a4b2a4845d2708d0f30290be8 100644 (file)
@@ -1009,16 +1009,20 @@ function hideOrShowFeedsCategory(doc, node, hide, cat_node) {
        //                      debug(node.childNodes[i].id + " --> " + has_unread);
        
                                if (hide && !has_unread) {
-                                       node.childNodes[i].style.display = "none";
+                                       //node.childNodes[i].style.display = "none";
+                                       Effect.DropOut(node.childNodes[i], {duration : 0.3});
                                }
        
                                if (!hide) {
                                        node.childNodes[i].style.display = "list-item";
+                                       //Effect.Appear(node.childNodes[i], {duration : 0.3});
                                }
        
                                if (has_unread) {
                                        node.childNodes[i].style.display = "list-item";
                                        cat_unread++;
+                                       //Effect.Appear(node.childNodes[i], {duration : 0.3});
+                                       //Effect.Highlight(node.childNodes[i]);
                                }
                        }
                }
index 51c2dd17eece05c35419c8ff301668576e0c2979..8e003e5a954a2d6897019080d4b32cc6a2166861 100644 (file)
                                        }
 
                                        if ($collapsed == "t" || $collapsed == "1") {
-                                               $holder_class = "invisible";
+                                               $holder_class = "feedCatHolder";
+                                               $holder_style = "display:none;";
                                                $ellipsis = "...";
                                        } else {
                                                $holder_class = "feedCatHolder";
+                                               $holder_style = "";
                                                $ellipsis = "";
                                        }
 
 
                                        // !!! NO SPACE before <ul...feedCatList - breaks firstChild DOM function
                                        // -> keyboard navigation, etc.
-                                       print "<li id=\"feedCatHolder\" class=\"$holder_class\"><ul class=\"feedCatList\" id=\"FCATLIST-$cat_id\">";
+                                       print "<li id=\"feedCatHolder\" class=\"$holder_class\"><ul class=\"feedCatList\" id=\"FCATLIST-$cat_id\" style='$holder_style'>";
                                }
        
                                printFeedEntry($feed_id, $class, $feed, $unread,