protected override async Task <bool> RefreshedOwnedItems(MetadataRefreshOptions options, List <FileSystemInfo> fileSystemChildren, CancellationToken cancellationToken) { var hasChanges = await base.RefreshedOwnedItems(options, fileSystemChildren, cancellationToken).ConfigureAwait(false); if (IsStacked) { var tasks = AdditionalParts .Select(i => RefreshMetadataForOwnedVideo(options, i, cancellationToken)); await Task.WhenAll(tasks).ConfigureAwait(false); } // Must have a parent to have additional parts or alternate versions // In other words, it must be part of the Parent/Child tree // The additional parts won't have additional parts themselves if (LocationType == LocationType.FileSystem && Parent != null) { if (!IsStacked) { RefreshLinkedAlternateVersions(); var tasks = LocalAlternateVersions .Select(i => RefreshMetadataForOwnedVideo(options, i, cancellationToken)); await Task.WhenAll(tasks).ConfigureAwait(false); } } return(hasChanges); }
public IEnumerable <Guid> GetAdditionalPartIds() { return(AdditionalParts.Select(i => LibraryManager.GetNewItemId(i, typeof(Video)))); }