[gnome-music/wip/jfelder/mpris-fix-playlisttype: 9/9] mpris: Prevent a cash from play call with no playlist
- From: Jean Felder <jfelder src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-music/wip/jfelder/mpris-fix-playlisttype: 9/9] mpris: Prevent a cash from play call with no playlist
- Date: Thu, 6 Sep 2018 11:58:19 +0000 (UTC)
commit f568801eaee4ca101c16bed559fbb0b94a1f0640
Author: Jean Felder <jfelder src gnome org>
Date: Wed Sep 5 19:14:48 2018 +0200
mpris: Prevent a cash from play call with no playlist
When trying to play a song launch from a MPRIS client when no playlist
is set, the first song from the SongsView is loaded. This results in a
crash as the PlayerPlaylist.Type is wrong.
Fix it by using the correct name.
gnomemusic/mpris.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/gnomemusic/mpris.py b/gnomemusic/mpris.py
index 97183942..dce483de 100644
--- a/gnomemusic/mpris.py
+++ b/gnomemusic/mpris.py
@@ -467,7 +467,7 @@ class MediaPlayer2Service(Server):
if self.first_song_handler:
model.disconnect(self.first_song_handler)
self.first_song_handler = 0
- self.player.set_playlist(PlayerPlaylist.Type.SONG, None, model, iter_)
+ self.player.set_playlist(PlayerPlaylist.Type.SONGS, None, model, iter_)
self.player.play()
@log
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]