[vlc-commits] qml: auto capture plmodel in playlist contextmenu

Fatih Uzunoglu git at videolan.org
Tue Aug 18 17:14:59 CEST 2020


vlc | branch: master | Fatih Uzunoglu <fuzun54 at outlook.com> | Tue Jul 14 21:07:04 2020 +0300| [5327d00c2038ebe2447508ca8bd8a45c92e42333] | committer: Pierre Lamot

qml: auto capture plmodel in playlist contextmenu

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=5327d00c2038ebe2447508ca8bd8a45c92e42333
---

 modules/gui/qt/playlist/qml/PlaylistListView.qml | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/modules/gui/qt/playlist/qml/PlaylistListView.qml b/modules/gui/qt/playlist/qml/PlaylistListView.qml
index 5621d83068..ff4a2c0b7c 100644
--- a/modules/gui/qt/playlist/qml/PlaylistListView.qml
+++ b/modules/gui/qt/playlist/qml/PlaylistListView.qml
@@ -132,7 +132,7 @@ Widgets.NavigableFocusScope {
 
         Widgets.MenuExt {
             id: contextMenu
-            property var model: ({})
+            property alias model: root.plmodel
             property bool medialibAvailable: false
             closePolicy: Popup.CloseOnReleaseOutside | Popup.CloseOnEscape
 
@@ -323,7 +323,6 @@ Widgets.NavigableFocusScope {
                             {
                                 view.forceActiveFocus()
                                 root.plmodel.deselectAll()
-                                contextMenu.model = root.plmodel
                                 contextMenu.popup()
                             }
                             else if ( mouse.button === Qt.LeftButton )
@@ -416,7 +415,6 @@ Widgets.NavigableFocusScope {
 
                             if (button === Qt.RightButton)
                             {
-                                contextMenu.model = root.plmodel
                                 contextMenu.popup()
                             }
                         }



More information about the vlc-commits mailing list