Remove pyspotify test code
This commit is contained in:
parent
72a2215621
commit
ff95f6e448
@ -81,7 +81,6 @@ class LibspotifySessionManager(SpotifySessionManager, threading.Thread):
|
|||||||
threading.Thread.__init__(self)
|
threading.Thread.__init__(self)
|
||||||
self.backend = backend
|
self.backend = backend
|
||||||
self.audio = AlsaController()
|
self.audio = AlsaController()
|
||||||
self.queued = False
|
|
||||||
|
|
||||||
def run(self):
|
def run(self):
|
||||||
self.connect()
|
self.connect()
|
||||||
@ -121,22 +120,3 @@ class LibspotifySessionManager(SpotifySessionManager, threading.Thread):
|
|||||||
|
|
||||||
def end_of_track(self, session):
|
def end_of_track(self, session):
|
||||||
logger.debug('End of track')
|
logger.debug('End of track')
|
||||||
|
|
||||||
def test(self):
|
|
||||||
# XXX This should play the first song in your first playlist :-)
|
|
||||||
playlist_no = 0
|
|
||||||
track_no = 0
|
|
||||||
try:
|
|
||||||
if not self.queued:
|
|
||||||
if len(self.playlists) > playlist_no:
|
|
||||||
playlist = self.playlists[playlist_no]
|
|
||||||
if playlist.is_loaded():
|
|
||||||
if playlist[track_no].is_loaded():
|
|
||||||
session.load(playlist[track_no])
|
|
||||||
session.play(1)
|
|
||||||
self.queued = True
|
|
||||||
logger.info('Playing "%s"',
|
|
||||||
playlist[track_no].name())
|
|
||||||
except Exception, e:
|
|
||||||
logger.exception(e)
|
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user