[gnome-music/wip/mschraal/core: 28/93] coresong: Remove property setting duplication
- From: Marinus Schraal <mschraal src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-music/wip/mschraal/core: 28/93] coresong: Remove property setting duplication
- Date: Fri, 21 Jun 2019 22:43:02 +0000 (UTC)
commit f043790f1c190d2261bb971db442611d63f3ca8a
Author: Marinus Schraal <mschraal gnome org>
Date: Thu May 9 21:34:32 2019 +0200
coresong: Remove property setting duplication
gnomemusic/coresong.py | 10 +---------
1 file changed, 1 insertion(+), 9 deletions(-)
---
diff --git a/gnomemusic/coresong.py b/gnomemusic/coresong.py
index 8b4b7f2b..a0ef381c 100644
--- a/gnomemusic/coresong.py
+++ b/gnomemusic/coresong.py
@@ -28,15 +28,7 @@ class CoreSong(GObject.GObject):
self._favorite = False
- self.props.media = media
- self.props.album = utils.get_album_title(media)
- self.props.album_disc_number = media.get_album_disc_number()
- self.props.artist = utils.get_artist_name(media)
- self.props.favorite = media.get_favourite()
- self.props.play_count = media.get_play_count()
- self.props.title = utils.get_media_title(media)
- self.props.track_number = media.get_track_number()
- self.props.url = media.get_url()
+ self.update(media)
if self.props.favorite:
print("favorite", self.props.title)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]