Commit Graph

2 Commits

Author SHA1 Message Date
Tobias Doerffel
d3bb3ff13a ResourceModel: implement filter functionality
So far all subclasses implemented filtering on their own which doesn't
make much sense. Now one can set filter keywords and a filter type for
all ResourceModels. Subclasses simply have to call
ResourceModel::itemMatchesFilter( ResourceItem ) in order to determine
whether an item should be hidden or not. Additionally they have to
implement the updateFilters() method in order to update their internal
management data each time the filters change.
2009-08-21 18:10:38 +02:00
Tobias Doerffel
cc987b2e6a ResourceListModel: new model providing resources in a flat list
The new ResourceListModel implements a ResourceModel to be used with
QListView & friends. It provides all items of the given ResourceDB as
a flat unsorted list. It'll be mainly used for the upcoming
QuickLoadDialog.

ResourceListModel features an internal lookup table, resulting in very
good performance when filtering (even with thousands of items).
2009-08-18 00:15:14 +02:00