[vlc-commits] [Git][videolan/vlc][master] macosx: prevent dropping play queue items onto rows

Jean-Baptiste Kempf (@jbk) gitlab at videolan.org
Sat Aug 1 05:28:43 UTC 2026



Jean-Baptiste Kempf pushed to branch master at VideoLAN / VLC


Commits:
3b676e01 by Serhii Bykov at 2026-08-01T06:57:49+02:00
macosx: prevent dropping play queue items onto rows

- - - - -


1 changed file:

- modules/gui/macosx/playqueue/VLCPlayQueueDataSource.m


Changes:

=====================================
modules/gui/macosx/playqueue/VLCPlayQueueDataSource.m
=====================================
@@ -114,6 +114,18 @@ static NSString *VLCPlayQueueCellIdentifier = @"VLCPlayQueueCellIdentifier";
                  proposedRow:(NSInteger)row
        proposedDropOperation:(NSTableViewDropOperation)dropOperation
 {
+    // Make drops at the end of the table go to the end.
+    if (row == -1) {
+        row = tableView.numberOfRows;
+        dropOperation = NSTableViewDropAbove;
+        [tableView setDropRow:row dropOperation:dropOperation];
+    }
+
+    // We don't ever want to drop onto a row, only between rows.
+    if (dropOperation == NSTableViewDropOn) {
+        [tableView setDropRow:row + 1 dropOperation:NSTableViewDropAbove];
+    }
+
     return NSDragOperationCopy;
 }
 



View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/3b676e01955fb45cf021dc50c74f4778d9316bca

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/3b676e01955fb45cf021dc50c74f4778d9316bca
You're receiving this email because of your account on code.videolan.org. Manage all notifications: https://code.videolan.org/-/profile/notifications | Help: https://code.videolan.org/help




More information about the vlc-commits mailing list