[gnome-music/wip/jfelder/playlistview-random-song: 3/7] playlistview: Remove unecessary check
- From: Jean Felder <jfelder src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-music/wip/jfelder/playlistview-random-song: 3/7] playlistview: Remove unecessary check
- Date: Wed, 24 Apr 2019 21:17:55 +0000 (UTC)
commit 21d963b7b25417d5b4ca002528f317cc7d006059
Author: Jean Felder <jfelder src gnome org>
Date: Mon Apr 15 17:23:28 2019 +0200
playlistview: Remove unecessary check
set_playlist method from the PlayerPlaylist also checks if the
requested song can be played and tries to play the next song if
necessary.
gnomemusic/views/playlistview.py | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
---
diff --git a/gnomemusic/views/playlistview.py b/gnomemusic/views/playlistview.py
index 8a0e7c19..b0734dfb 100644
--- a/gnomemusic/views/playlistview.py
+++ b/gnomemusic/views/playlistview.py
@@ -352,11 +352,10 @@ class PlaylistView(BaseView):
return
_iter = self.model.get_iter(path)
- if self.model[_iter][8] != self._error_icon_name:
- self.player.set_playlist(
- PlayerPlaylist.Type.PLAYLIST,
- self._current_playlist.get_id(), self.model, _iter)
- self.player.play()
+ playlist_id = self._current_playlist.get_id()
+ self.player.set_playlist(
+ PlayerPlaylist.Type.PLAYLIST, playlist_id, self.model, _iter)
+ self.player.play()
# 'row-activated' signal is emitted before 'drag-begin' signal.
# Need to wait to check if drag and drop operation is active.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]