diff options
author | Andrew Dolgov <[email protected]> | 2014-11-12 09:45:57 +0300 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2014-11-12 09:45:57 +0300 |
commit | 7e2a789a35e9902cb60dd53ea802f61767329eff (patch) | |
tree | 5bf840ceacfcb27beb94beddb31e32fdbff6f59d /org.fox.ttrss/src/main | |
parent | 487d05e6c011fe517ff0fa30e3b6920b995f3169 (diff) |
in flat feedlist mode, put all special feeds in a single category
Diffstat (limited to 'org.fox.ttrss/src/main')
-rw-r--r-- | org.fox.ttrss/src/main/java/org/fox/ttrss/FeedsFragment.java | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/org.fox.ttrss/src/main/java/org/fox/ttrss/FeedsFragment.java b/org.fox.ttrss/src/main/java/org/fox/ttrss/FeedsFragment.java index 31dc0ae4..a1367b8d 100644 --- a/org.fox.ttrss/src/main/java/org/fox/ttrss/FeedsFragment.java +++ b/org.fox.ttrss/src/main/java/org/fox/ttrss/FeedsFragment.java @@ -543,12 +543,23 @@ public class FeedsFragment extends Fragment implements OnItemClickListener, OnSh for (Feed f : feeds) if (f.id > -10 || m_catId != -4) { // skip labels for flat feedlist for now - m_feeds.add(f); - catUnread += f.unread; + if (m_activeCategory != null || f.id >= 0) { + m_feeds.add(f); + catUnread += f.unread; + } } sortFeeds(); + if (m_activeCategory == null) { + Feed feed = new Feed(-1, "Special", true); + feed.unread = catUnread; + + m_feeds.add(0, feed); + m_adapter.notifyDataSetChanged(); + + } + if (m_enableParentBtn && m_activeCategory != null && m_activeCategory.id >= 0 && m_feeds.size() > 0) { Feed feed = new Feed(m_activeCategory.id, m_activeCategory.title, true); feed.unread = catUnread; |