}
},
+ getFeedCategory: function(feed) {
+ try {
+ return this.getNodesByItem(this.model.store.
+ _itemsByIdentity["FEED:" + feed])[0].
+ getParent().item.bare_id[0];
+ } catch (e) {
+ return false;
+ }
+ },
});
return -1;
}
+function getFeedCategory(feed) {
+ try {
+ var tree = dijit.byId("feedTree");
+
+ if (tree && tree.model)
+ return tree.getFeedCategory(feed);
+
+ } catch (e) {
+ //
+ }
+
+ return false;
+}
+
function hideOrShowFeeds(hide) {
var tree = dijit.byId("feedTree");
console.log(query);
+ if (article_is_unread) {
+ var ctr = getFeedUnread(getActiveFeedId(), activeFeedIsCat());
+
+ if (ctr > 0) {
+ setFeedUnread(getActiveFeedId(), activeFeedIsCat(), ctr - 1);
+
+ var cat = parseInt(getFeedCategory(getActiveFeedId()));
+
+ if (!isNaN(cat)) {
+ ctr = getFeedUnread(cat, true);
+
+ if (ctr > 0) {
+ setFeedUnread(cat, true, ctr - 1);
+ }
+ }
+ }
+ }
+
new Ajax.Request("backend.php", {
parameters: query,
onComplete: function(transport) {