Skip to content

Commit bc66638

Browse files
author
Hailin Gan
committed
Fix crash on drag and drop file to Playlist
1 parent 18b1c69 commit bc66638

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

YUViewLib/src/ui/widgets/PlaylistTreeWidget.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,10 @@ void PlaylistTreeWidget::dragMoveEvent(QDragMoveEvent *event)
194194
if (dropTarget)
195195
{
196196
auto draggedItems = selectedItems();
197+
if (draggedItems.size() <= 0){
198+
event->ignore();
199+
return;
200+
}
197201
auto draggedItem = dynamic_cast<playlistItem *>(draggedItems[0]);
198202

199203
// handle video items as target

0 commit comments

Comments
 (0)