public void DeleteRelease(Release release) { VerificationWindow verify = new VerificationWindow("This will permanently delete all files and images!"); if (verify.ShowDialog(Window.GetWindow(this.mainCollectionView)) == true) { //using (var transaction = this.CollectionManager.BeginTransaction()) //{ string releaseName = release.JoinedAlbumArtists + " - " + release.Title; if (!this.CollectionManager.DeleteRelease(release, true)) { Dialogs.Inform("Some files from " + releaseName + " were not deleted successfully. Please check by hand."); } //transaction.Commit(); //} CollectionManagerGlobal.OnCollectionChanged(); } }
public void DeleteRelease(Release release) { VerificationWindow verify = new VerificationWindow("This will permanently delete all files and images!"); if (verify.ShowDialog(Window.GetWindow(this.mainCollectionView)) == true) { //using (var transaction = this.CollectionManager.BeginTransaction()) //{ string releaseName = release.JoinedAlbumArtists + " - " + release.Title; if (!this.CollectionManager.DeleteRelease(release, true)) { Dialogs.Inform("Some files from " + releaseName + " were not deleted successfully. Please check by hand."); } //transaction.Commit(); //} CollectionManagerGlobal.OnCollectionChanged(); } }