Felix Paul Kühne pushed to branch master at VideoLAN / VLC


Commits:
7507fca2 by Claudio Cambra at 2026-05-02T17:57:32+02:00
macosx: Avoid crash by reloading whole media source collection view on change

Signed-off-by: Claudio Cambra <[email protected]>

- - - - -


1 changed file:

- modules/gui/macosx/library/media-source/VLCMediaSourceBaseDataSource.m


Changes:

=====================================
modules/gui/macosx/library/media-source/VLCMediaSourceBaseDataSource.m
=====================================
@@ -650,16 +650,7 @@ referenceSizeForHeaderInSection:(NSInteger)section
         _lanDeviceSnapshot = [self buildLANDeviceSnapshot];
     }
     if (self.viewMode == VLCLibraryGridViewModeSegment) {
-        const NSInteger index = [_mediaSources 
indexOfObject:aNotification.object];
-        const BOOL inSync =
-            self.collectionView.numberOfSections == 
(NSInteger)_mediaSources.count;
-        if (self.collectionView.dataSource == self
-            && index != NSNotFound
-            && inSync) {
-            [self.collectionView reloadSections:[NSIndexSet 
indexSetWithIndex:index]];
-        } else {
-            [self.collectionView reloadData];
-        }
+        [self.collectionView reloadData];
     } else {
         [self.tableView reloadData];
     }



View it on GitLab: 
https://code.videolan.org/videolan/vlc/-/commit/7507fca293a2c77c713834f9ee85509cf1bef553

-- 
View it on GitLab: 
https://code.videolan.org/videolan/vlc/-/commit/7507fca293a2c77c713834f9ee85509cf1bef553
You're receiving this email because of your account on code.videolan.org.


_______________________________________________
vlc-commits mailing list
[email protected]
https://mailman.videolan.org/listinfo/vlc-commits

Reply via email to