Connected PlaylistView.itemDoubleClicked to a function that then tells the player to play that track.
This commit is contained in:
parent
8fbb40d2f9
commit
da27963884
5 changed files with 34 additions and 6 deletions
|
@ -52,6 +52,15 @@ class Player:
|
|||
self.track_progress.start()
|
||||
self.app.gui_communication.on_track_start()
|
||||
|
||||
def play_track_in_playlist(self, track_index):
|
||||
self.stop()
|
||||
|
||||
self.current_sound, self.current_sound_duration = self.current_playlist.set_track(track_index)
|
||||
|
||||
self.play()
|
||||
self.track_progress.start()
|
||||
self.app.gui_communication.on_track_start()
|
||||
|
||||
def pause(self):
|
||||
self.music_channel.pause()
|
||||
self.track_progress.pause()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue