[gnome-music/pl-artists-fixes: 2/3] widgets: Use artist name as playlist id for Artists view
- From: Arnel A. Borja <arnelborja src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-music/pl-artists-fixes: 2/3] widgets: Use artist name as playlist id for Artists view
- Date: Wed, 9 Apr 2014 08:46:04 +0000 (UTC)
commit cbb8e7e49041615d31b6e3a2a4a1b37e7c1c5616
Author: Arnel A. Borja <arnelborja src gnome org>
Date: Wed Apr 9 15:45:59 2014 +0800
widgets: Use artist name as playlist id for Artists view
This allows the Artists view to easily lookup if the running playlist is
from itself.
https://bugzilla.gnome.org/show_bug.cgi?id=705852
gnomemusic/widgets.py | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/gnomemusic/widgets.py b/gnomemusic/widgets.py
index c61ac4f..7435a64 100644
--- a/gnomemusic/widgets.py
+++ b/gnomemusic/widgets.py
@@ -416,7 +416,7 @@ class ArtistAlbums(Gtk.VBox):
@log
def add_album(self, album):
- widget = ArtistAlbumWidget(album, self.player, self.model)
+ widget = ArtistAlbumWidget(self.artist, album, self.player, self.model)
self._albumBox.pack_start(widget, False, False, 0)
self.widgets.append(widget)
@@ -541,11 +541,11 @@ class AllArtistsAlbums(ArtistAlbums):
class ArtistAlbumWidget(Gtk.HBox):
@log
- def __init__(self, album, player, model):
+ def __init__(self, artist, album, player, model):
super(Gtk.HBox, self).__init__()
self.player = player
self.album = album
- self.artist = album.get_string(Grl.METADATA_KEY_ARTIST)
+ self.artist = artist
self.model = model
self.songs = []
self.monitors = []
@@ -646,7 +646,7 @@ class ArtistAlbumWidget(Gtk.HBox):
return
self.player.stop()
- self.player.set_playlist('Artist', self.album,
+ self.player.set_playlist('Artist', self.artist,
widget.model, widget._iter, 5)
self.player.set_playing(True)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]