[Banshee-List] Smartplaylists & normalized model


I have been following the discussion about the Smart play lists and i
will like to contribute with my ideas about the subject.

First i do not think that the way of leaving that to the database,
either working with views or selects will bring a great performance to
the application, specially because you will be force to reload the whole
model from the DB every time something change in one track, i think the
best to go is to have only one store and filter those using stacked
models, i already did that change for my normalized patch. I also
replaced the normal play list mechanism to use a TreeModelFilter on top
on a ListStore, in the future we could replace those store by 100%
managed ones to reduce the amount of marshaling that occurs, but for the
moment appear to be working good enough.

I think Smart play list could work exactly the same way only using a
dynamically generated filter, then the live update will come for free
without any reloading of the model.

Please take a look of my current Browser implementation, you can change
the Genre of a track and that will disappear automatically from the
Genre view, this also do not put a lot of load into the processor
because only that one track is reprocessed. And we could add some View
caching to have the pre-filtered models/views already in memory, there a
balance will be needed between speed and resource usage but i think is a
good way to solve the issue.

To do the check apply the patch to a clean 0.10.9, better if you use CVS
to get it and autogen to configure it.

Sorting is deactivated because the implementation of TreeModelSort is
crap, if i set that then out of nothing rows start to disappear every
time you browse until an unknown exception is thrown. To my
understanding the Sort model should not change the visibility of any of
the rows so this has to be a bug in the way they implemented. I think i
will have to create my own implementation of this but i do not have
enough time this week.

After checking the browser go to a genre/artist/album and change the
value in one of the tracks for something different to the value you have
selected. The track should disappear of the list!

Please check it, also you Aaron if you happen to have 30 free minutes.



Attachment: banshee-normalized.patch.bz2
Description: application/bzip

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]