Dnia 2009-03-26, czw o godzinie 19:03 +0100, Olivier Tilloy pisze:
> Hi Krzysztof,
> 
> That's a quite thorough analysis of the situation!
> As you may have noticed, the slideshow player has been recently
> re-modelled. It is now much better (and, I think, a piece of Elisa we
> can now be proud of). Its API is quite consistent because carefully
> designed, so I think most of the changes you are proposing ought to be
> done in the video/audio player to reflect changes in the slideshow player.
> 
> Now, until which point it is relevant to try and unify the two players'
> APIs is another open question. Some methods of the slideshow are for
> example quite specific to a slideshow and don't really fit in a
> video/audio player.
> 
> Any concrete proposal of what should be done, or even a design or
> proof-of-concept branch are more than welcome!
Sorry for responding so late. What i would like to do is to make
BasePlayer class that will contain as much of the code that could be
shared between all the players (slideshow and video for now) as
possible. 
As a good start i think that the code for handling playlists could be
unified and stored in base class. 
It is obvious that all players will have a playlist and operations on
this playlist will be the same:
- set playlist
- clear playlist
- get current item from playlist
- add something to playlist
- remove something from playlist

The problem is that video player uses PlaylistModel() class while
slideshow uses just normal python lists. Do you think this could be
generalized somehow? Should PlaylistModel be used or just a normal list
in both players? Or maybe you think it's not a good idea to have this
code shared between players?

-- 
Krzysztof Adamski
KORBANK sp. z o.o. ul.Nabycińska 19 Wrocław
tel. +48 71 7234323 http://www.k.pl 

Reply via email to