Update of /cvsroot/freevo/freevo/src
In directory sc8-pr-cvs1:/tmp/cvs-serv32540

Modified Files:
        playlist.py directory.py 
Log Message:
add recursive _not_ random playlist

Index: playlist.py
===================================================================
RCS file: /cvsroot/freevo/freevo/src/playlist.py,v
retrieving revision 1.28
retrieving revision 1.29
diff -C2 -d -r1.28 -r1.29
*** playlist.py 17 Oct 2003 18:50:10 -0000      1.28
--- playlist.py 18 Oct 2003 08:13:35 -0000      1.29
***************
*** 10,13 ****
--- 10,16 ----
  # -----------------------------------------------------------------------
  # $Log$
+ # Revision 1.29  2003/10/18 08:13:35  dischi
+ # add recursive _not_ random playlist
+ #
  # Revision 1.28  2003/10/17 18:50:10  dischi
  # random playlist can now be non-recursive, too
***************
*** 331,335 ****
  
  class RandomPlaylist(Playlist):
!     def __init__(self, playlist, parent, add_args = None, recursive = True):
          Item.__init__(self, parent)
          self.type     = 'playlist'
--- 334,338 ----
  
  class RandomPlaylist(Playlist):
!     def __init__(self, playlist, parent, add_args = None, recursive = True, random = 
True):
          Item.__init__(self, parent)
          self.type     = 'playlist'
***************
*** 341,344 ****
--- 344,349 ----
          self.unplayed     = playlist
          self.recursive    = recursive
+         self.random       = random
+ 
          
      def actions(self):
***************
*** 347,351 ****
  
      def play_next(self, arg=None, menuw=None):
!         element = random.choice(self.unplayed)
          self.unplayed.remove(element)
          if not callable(element):
--- 352,359 ----
  
      def play_next(self, arg=None, menuw=None):
!         if self.random:
!             element = random.choice(self.unplayed)
!         else:
!             element = self.unplayed[0]
          self.unplayed.remove(element)
          if not callable(element):

Index: directory.py
===================================================================
RCS file: /cvsroot/freevo/freevo/src/directory.py,v
retrieving revision 1.50
retrieving revision 1.51
diff -C2 -d -r1.50 -r1.51
*** directory.py        17 Oct 2003 18:50:45 -0000      1.50
--- directory.py        18 Oct 2003 08:13:35 -0000      1.51
***************
*** 10,13 ****
--- 10,16 ----
  # -----------------------------------------------------------------------
  # $Log$
+ # Revision 1.51  2003/10/18 08:13:35  dischi
+ # add recursive _not_ random playlist
+ #
  # Revision 1.50  2003/10/17 18:50:45  dischi
  # add description to configure menu and make random playlist for video, too
***************
*** 436,440 ****
                           _('Random play all items')),
                         ( RandomPlaylist((self.dir, suffix), self),
!                          _('Recursive random play all items')) ]
          
          items.append((self.configure, _('Configure directory'), 'configure'))
--- 439,445 ----
                           _('Random play all items')),
                         ( RandomPlaylist((self.dir, suffix), self),
!                          _('Recursive random play all items')), 
!                        ( RandomPlaylist((self.dir, suffix), self, random = False),
!                          _('Recursive play all items')) ]
          
          items.append((self.configure, _('Configure directory'), 'configure'))




-------------------------------------------------------
This SF.net email sponsored by: Enterprise Linux Forum Conference & Expo
The Event For Linux Datacenter Solutions & Strategies in The Enterprise 
Linux in the Boardroom; in the Front Office; & in the Server Room 
http://www.enterpriselinuxforum.com
_______________________________________________
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog

Reply via email to