diff options
-rw-r--r-- | feedlist.js | 7 | ||||
-rw-r--r-- | functions.php | 4 | ||||
-rwxr-xr-x[-rw-r--r--] | images/cat-collapse.png | bin | 161 -> 1232 bytes | |||
-rwxr-xr-x | images/cat-uncollapse.png | bin | 0 -> 1242 bytes | |||
-rw-r--r-- | tt-rss.css | 4 |
5 files changed, 14 insertions, 1 deletions
diff --git a/feedlist.js b/feedlist.js index 3dfc98cbf..b1608ec18 100644 --- a/feedlist.js +++ b/feedlist.js @@ -371,6 +371,13 @@ function toggleCollapseCat(cat) { Effect.toggle('FCATLIST-' + cat, 'blind', { duration: 0.5, afterFinish: toggleCollapseCat_af }); + var img = cat_elem.getElementsByTagName("IMG")[0]; + + if (img.src.match("-collapse")) + img.src = img.src.replace("-collapse", "-uncollapse") + else + img.src = img.src.replace("-uncollapse", "-collapse") + new Ajax.Request("backend.php", { parameters: "backend.php?op=feeds&subop=collapse&cid=" + param_escape(cat) } ); diff --git a/functions.php b/functions.php index 7ab6fabb3..127704990 100644 --- a/functions.php +++ b/functions.php @@ -4275,9 +4275,11 @@ if ($hidden) { $holder_style = "display:none;"; $ellipsis = "…"; + $collapse_pic = "cat-uncollapse.png"; } else { $holder_style = ""; $ellipsis = ""; + $collapse_pic = "cat-collapse.png"; } $catctr_class = ($cat_unread > 0) ? "catCtrHasUnread" : "catCtrNoUnread"; @@ -4295,7 +4297,7 @@ print "<li class=\"$cat_class\" id=\"FCAT-$cat_id\"> <img onclick=\"toggleCollapseCat($cat_id)\" class=\"catCollapse\" title=\"".__('Click to collapse category')."\" - src=\"images/cat-collapse.png\"><span class=\"$inner_title_class\" + src=\"images/$collapse_pic?\"><span class=\"$inner_title_class\" id=\"FCATN-$cat_id\" $browse_cat_link/>$tmp_category</span>"; print "<span id=\"FCAP-$cat_id\">"; diff --git a/images/cat-collapse.png b/images/cat-collapse.png Binary files differindex dc6edaf3b..ee4cebb75 100644..100755 --- a/images/cat-collapse.png +++ b/images/cat-collapse.png diff --git a/images/cat-uncollapse.png b/images/cat-uncollapse.png Binary files differnew file mode 100755 index 000000000..926bc5fdb --- /dev/null +++ b/images/cat-uncollapse.png diff --git a/tt-rss.css b/tt-rss.css index de097042f..166b79fc0 100644 --- a/tt-rss.css +++ b/tt-rss.css @@ -134,6 +134,10 @@ ul.feedList li.feedCat, ul.feedList li.virtCat { ul.feedList img.catCollapse { cursor : pointer; + vertical-align : middle; + width : 11px; + height : 11px; + padding-bottom : 3px; } ul.feedList span.catTitle { |