libsaria: Rename playlist's next() function

This is to prepare for creating a new file "next.py" dedicated to
choosing the next song.  I also use this as an opportunity to pass the
current song id to the next function.
This commit is contained in:
Bryan Schumaker 2011-05-14 07:48:11 -04:00
parent a950f06e10
commit 0a1160f618
2 changed files with 2 additions and 2 deletions

View File

@ -65,7 +65,7 @@ def next():
global cur_id
cur_id = queue.next()
if cur_id == None:
cur_id = playlist.next()
cur_id = playlist.get_next(cur_id)
return library.get_attrs(cur_id, "filepath")
def list_source(source, *attrs):

View File

@ -106,7 +106,7 @@ def play_id(id):
return True
return False
def next():
def get_next(cur_id):
id = None
if len(playlist.song_list) == 0:
return