Skip to content

Synchronize feed count whenever Feed Commas communicates with a backend.

Michał Góral requested to merge fix/issue-10 into master

It means that currently there are two situations when feed count (in menu) is updated: - when user changes currently highlighted feed - when user navigates feeds (next "page" is loaded)

This is because CommaFeed likes to fetch feeds at the time user navigates some of them. In this case there could be displayed more unread feeds than it'd be indicated in the menu. It's a workaround for this situation (though there could still be a race condition between two requests to CF - it's unavoidable because of the way how CF's API is designed [we can't atomically get all the information we want]).

Also, because it'd look strange otherwise, we'll now use DisplayController.load(), which has additional effect of blocking interface until everything's loaded, so we work around another issue which occurs when user quickly selects many different feeds or categories (we can't be sure which would be loaded first). Note that Feed Commas can be still exited by pressing Ctrl-C, even when blocked. The proper solution, however, would be implementing request queue (see issues #9 and #14), but if CF would be very slow to respond, the interface would still look unresponsive to the user.

This fixes issue #10 (closed)

Merge request reports