01org/dleyna-control — pull request #10 by jku (2013-03-07 10:02:06+00:00)
Title: [Model] Auto-load items also when max_items is not known

This is my suggestion for dealing with servers that do not include "max_items" in search results. I was originally thinking of additional UI (e.g. "next or "previous" buttons) but it seems just loading more items when you scroll near the end works quite well with the asynchronous loading. This doesn't stop us adding buttons or otherwise informing the user but it already works as a basic solution.

Not that it's just one commit on top of the browse-branch.

Commit mostly removes special cases for the servers that do not support max_items:This means that scrolling close to the end of the list will make new items appear at the end of the list. This affects things like scrollbar handle size and location but it is no longer annoying as scrolling is still fairly smooth (as smooth as it can be when items are added into a TreeView, I believe).

Also added GenericModel.length_is_known() so we can still avoid unnecessary TreeView.get_visible_range() calls with servers that do announce max_items.