Browse Source

macosx: Don't check modified input items if they have already been checked for media library folder refresh

Signed-off-by: Claudio Cambra <developer@claudiocambra.com>
pull/162/head
Claudio Cambra 3 years ago
committed by Steve Lhomme
parent
commit
f68058b826
  1. 6
      modules/gui/macosx/panels/VLCInformationWindowController.m

6
modules/gui/macosx/panels/VLCInformationWindowController.m

@ -514,11 +514,17 @@ SET_INPUTITEM_PROP(field, field) \
VLCLibraryController * const libraryController = VLCMain.sharedInstance.libraryController;
NSArray<VLCMediaLibraryEntryPoint *> * const entryPoints = libraryController.libraryModel.listOfMonitoredFolders;
NSMutableSet<NSString *> * const reloadMRLs = NSMutableSet.set;
NSMutableSet<VLCInputItem *> * const checkedInputItems = NSMutableSet.set;
for (VLCMediaLibraryEntryPoint * const entryPoint in entryPoints) {
for (VLCInputItem * const inputItem in inputItems) {
if ([checkedInputItems containsObject:inputItem]) {
continue;
}
if ([inputItem.MRL hasPrefix:entryPoint.MRL]) {
[reloadMRLs addObject:entryPoint.MRL];
[checkedInputItems addObject:inputItem];
break;
}
}

Loading…
Cancel
Save