public void ExcludeFile(FileEntry file) { // TODO: check for directory ItsIncludedFileEntriesDict.Remove(file.GetHashCode()); ItsExcludedFileEntries.Add(file); ItsNewFileEntries.Remove(file); // TODO: update xml RaiseRegistryUpdateEvent(); ItsInstallerProjectManagementService.RemoveFile(file.FullPath); }
private void BakeMetadataAvailableEventHandler(object sender, SingleEventArgs<BakeMetadata> e) { _bakeMetadata = e.ItsValue; if (_bakeMetadata == null) return; var comp = _bakeMetadata.ItsMainExecutableComponent; foreach (var file in comp.ItsBakeFiles) { var p1 = ItsInstallerProjectManagementService.ItsInstallerProjectInfo.ItsProjectPaths.ItsRootPath; var fileinfo = new FileInfo(Path.Combine(p1, file.ItsSource)); var fileEntry = new FileEntry { DisplayTitle = Path.GetFileName(file.ItsSource), FullPath = file.ItsSource, SizeInfo = new StorageSizeInfo(fileinfo.Length) }; ItsIncludedFileEntriesDict.Add(fileEntry.GetHashCode(), fileEntry); } RaiseRegistryUpdateEvent(); }