[vlc-commits] qml/PlaylistMediaDisplay: Cancel drag when resetting the model
Benjamin Arnaud
git at videolan.org
Mon Mar 15 10:35:00 UTC 2021
vlc | branch: master | Benjamin Arnaud <benjamin.arnaud at videolabs.io> | Thu Mar 11 10:16:58 2021 +0100| [95a3b074637b388f6e5b6426e312629becc7a591] | committer: Pierre Lamot
qml/PlaylistMediaDisplay: Cancel drag when resetting the model
Signed-off-by: Pierre Lamot <pierre at videolabs.io>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=95a3b074637b388f6e5b6426e312629becc7a591
---
modules/gui/qt/medialibrary/qml/PlaylistMediaDisplay.qml | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/modules/gui/qt/medialibrary/qml/PlaylistMediaDisplay.qml b/modules/gui/qt/medialibrary/qml/PlaylistMediaDisplay.qml
index 20a0277184..4a14da18aa 100644
--- a/modules/gui/qt/medialibrary/qml/PlaylistMediaDisplay.qml
+++ b/modules/gui/qt/medialibrary/qml/PlaylistMediaDisplay.qml
@@ -129,6 +129,10 @@ Widgets.NavigableFocusScope {
parentId: initialId
onCountChanged: {
+ // NOTE: We need to cancel the Drag item manually when resetting. Should this be called
+ // from 'onModelReset' only ?
+ dragItem.Drag.cancel();
+
if (count === 0 || modelSelect.hasSelection) return;
resetFocus();
More information about the vlc-commits
mailing list