[gnome-music/wip/jfelder/baseview-model-reorder: 25/25] player: Remove obsolete discovery_status_field attribute
- From: Jean Felder <jfelder src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-music/wip/jfelder/baseview-model-reorder: 25/25] player: Remove obsolete discovery_status_field attribute
- Date: Mon, 19 Mar 2018 08:07:45 +0000 (UTC)
commit 4e9ed400b8336245ffbf0cd9334ef3d403e36533
Author: Jean Felder <jfelder src gnome org>
Date: Tue Mar 6 14:51:31 2018 +0100
player: Remove obsolete discovery_status_field attribute
This is now equal to 11 for all views.
gnomemusic/player.py | 10 +++-------
1 file changed, 3 insertions(+), 7 deletions(-)
---
diff --git a/gnomemusic/player.py b/gnomemusic/player.py
index df1bce96..96e1fe84 100644
--- a/gnomemusic/player.py
+++ b/gnomemusic/player.py
@@ -395,7 +395,7 @@ class Player(GObject.GObject):
self.playlist.insert_with_valuesv(
int(path.to_string()),
[self.Field.SONG, self.Field.DISCOVERY_STATUS],
- [new_row[5], new_row[self._discovery_status_field]])
+ [new_row[5], new_row[11]])
self._validate_next_track()
self._sync_prev_next()
@@ -764,18 +764,14 @@ class Player(GObject.GObject):
for row in model:
current_iter = new_model.insert_with_valuesv(
-1, [self.Field.SONG, self.Field.DISCOVERY_STATUS],
- [row[5], row[self._discovery_status_field]])
+ [row[5], row[11]])
if row[5].get_id() == song_id:
new_path = new_model.get_path(current_iter)
return new_model, new_path
- # FIXME: set the discovery field to 11 to be safe, but for some
- # models it is 12.
@log
- def set_playlist(
- self, type_, id_, model, iter_, discovery_status_field=11):
- self._discovery_status_field = discovery_status_field
+ def set_playlist(self, type_, id_, model, iter_):
self.playlist, playlist_path = self._create_model(model, iter_)
self.currentTrack = Gtk.TreeRowReference.new(
self.playlist, playlist_path)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]