private void DeleteSelectedPrintItem() { if (Dialog.AskForDelete()) { PrintItems.Remove(SelectedPrintItem); } }
private void AskAndDelete() { if (!Dialog.AskForDelete()) { return; } DeleteImp(); }
private void DeleteCurrentCollectionItem() { if (!Dialog.AskForDelete()) { return; } var itemToDelete = SelectedCollectionItem; SelectedCollectionItem = CollectionItems.Last(); OnPropertyChanged(nameof(SelectedCollectionItem)); _viewProvider.DeleteCollectionItem(itemToDelete.InnerObject.Id); CollectionItems.Remove(itemToDelete); }
private async void Delete() { if (!Dialog.AskForDelete()) { return; } LoaderState.ToBusy(); var selectedImages = Images.Where(x => x.IsSelected); await _viewProvider.Delete(selectedImages.Select(x => x.InnerObject)); Images.RemoveAll(selectedImages.ToArray()); LoaderState.ToIdle(); }