[gnome-music/wip/mschraal/searchview-selection-fixes] searchview: Correctly select single songs



commit 5ce078a26651df1d0bae1ee6a547bbf62374e533
Author: Marinus Schraal <mschraal gnome org>
Date:   Sat Feb 8 16:09:24 2020 +0100

    searchview: Correctly select single songs
    
    Single songs were not selected as the selected value on SongWidget was
    set, but did this is not bound to the CoreSong.
    
    Use the CoreSong to set the selection instead.

 gnomemusic/views/searchview.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/gnomemusic/views/searchview.py b/gnomemusic/views/searchview.py
index 65da0699..2f50633c 100644
--- a/gnomemusic/views/searchview.py
+++ b/gnomemusic/views/searchview.py
@@ -404,7 +404,7 @@ class SearchView(Gtk.Stack):
             with self._model.freeze_notify():
                 def song_select(child):
                     song_widget = child.get_child()
-                    song_widget.props.selected = value
+                    song_widget.props.coresong.props.selected = value
 
                 self._songs_listbox.foreach(song_select)
                 self._album_flowbox.foreach(child_select)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]