forked from Wobbl/Wobuzz
Added a "track_info"-toolbar which shows an image found in the current audio file's metadata (usually the front-cover) and information about the currently playing track such as title and artist name.
This commit is contained in:
parent
ccda6b30c8
commit
39bd7e3167
5 changed files with 101 additions and 5 deletions
|
@ -33,7 +33,7 @@ class Player:
|
|||
self.playing = True
|
||||
self.paused = False
|
||||
|
||||
self.app.gui.track_control.on_playstate_update()
|
||||
self.app.gui.on_playstate_update()
|
||||
|
||||
# cache next track so it immediately starts when the current track finishes
|
||||
self.cache_next_track()
|
||||
|
@ -68,7 +68,7 @@ class Player:
|
|||
|
||||
self.app.gui.on_track_change(self.history.h_last_track(), self.current_playlist.current_track)
|
||||
|
||||
self.app.gui.track_control.on_playstate_update()
|
||||
self.app.gui.on_playstate_update()
|
||||
|
||||
def play_track_in_playlist(self, track_index):
|
||||
self.stop()
|
||||
|
@ -99,7 +99,7 @@ class Player:
|
|||
self.track_progress.pause()
|
||||
self.paused = True
|
||||
|
||||
self.app.gui.track_control.on_playstate_update()
|
||||
self.app.gui.on_playstate_update()
|
||||
|
||||
def unpause(self):
|
||||
self.music_channel.unpause()
|
||||
|
@ -108,7 +108,7 @@ class Player:
|
|||
self.playing = True
|
||||
self.paused = False
|
||||
|
||||
self.app.gui.track_control.on_playstate_update()
|
||||
self.app.gui.on_playstate_update()
|
||||
|
||||
def next_track(self):
|
||||
if not self.current_playlist.on_last_track():
|
||||
|
@ -141,7 +141,7 @@ class Player:
|
|||
self.playing = False
|
||||
self.paused = False
|
||||
|
||||
self.app.gui.track_control.on_playstate_update()
|
||||
self.app.gui.on_playstate_update()
|
||||
|
||||
def seek(self, position: int):
|
||||
self.music_channel.stop()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue