private void Clear() { if (imageList.Images.Count > 0) { if (MessageBox.Show(string.Format(MiscResources.ConfirmClearItems, imageList.Images.Count), MiscResources.Clear, MessageBoxButtons.OKCancel, MessageBoxIcon.Question) == DialogResult.OK) { imageList.Delete(Enumerable.Range(0, imageList.Images.Count)); UpdateThumbnails(); changeTracker.HasUnsavedChanges = false; } } }
private async void SavePDF(List <ScannedImage> images) { if (await exportHelper.SavePDF(images, notify)) { if (appConfigManager.Config.DeleteAfterSaving) { SafeInvoke(() => { imageList.Delete(imageList.Images.IndiciesOf(images)); }); } } }