[vlc-commits] qml: fix selection not updating when artist is changed in MusicArtist
    Prince Gupta 
    git at videolan.org
       
    Thu Dec 10 09:34:53 UTC 2020
    
    
  
vlc | branch: master | Prince Gupta <guptaprince8832 at gmail.com> | Fri Nov 13 14:21:28 2020 +0530| [570e3de31afc725f8799365f4e6a2cc248dbdc66] | committer: Pierre Lamot
qml: fix selection not updating when artist is changed in MusicArtist
Signed-off-by: Pierre Lamot <pierre at videolabs.io>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=570e3de31afc725f8799365f4e6a2cc248dbdc66
---
 modules/gui/qt/medialibrary/qml/MusicArtist.qml | 6 ++++++
 1 file changed, 6 insertions(+)
diff --git a/modules/gui/qt/medialibrary/qml/MusicArtist.qml b/modules/gui/qt/medialibrary/qml/MusicArtist.qml
index 4573b9bc96..db3b79c431 100644
--- a/modules/gui/qt/medialibrary/qml/MusicArtist.qml
+++ b/modules/gui/qt/medialibrary/qml/MusicArtist.qml
@@ -249,6 +249,12 @@ Widgets.NavigableFocusScope {
             delegateModel: albumSelectionModel
             model: albumModel
 
+            Connections {
+                target: root
+                // selectionModel updates but doesn't trigger any signal, this forces selection update in view
+                onParentIdChanged: currentIndex = -1
+            }
+
             delegate: AudioGridItem {
                 id: audioGridItem
 
    
    
More information about the vlc-commits
mailing list