private void OnClickAddPrinter(object sender, EventArgs e) { DicomPrintConfig config = new DicomPrintConfig(); PrinterSettingsForm psf = new PrinterSettingsForm(config); if (psf.ShowDialog(this) == DialogResult.OK) { Config.Instance.Printers.Add(config); SaveSettings(); } }
private void OnClickPrinterSettings(object sender, EventArgs e) { if (lvPrinters.SelectedItems.Count == 0) { return; } ListViewItem lvi = lvPrinters.SelectedItems[0]; DicomPrintConfig config = (DicomPrintConfig)lvi.Tag; PrinterSettingsForm psf = new PrinterSettingsForm(config); if (psf.ShowDialog(this) == DialogResult.OK) { SaveSettings(); } else { LoadSettings(); } }
private void OnClickPrinterSettings(object sender, EventArgs e) { if (lvPrinters.SelectedItems.Count == 0) return; ListViewItem lvi = lvPrinters.SelectedItems[0]; DicomPrintConfig config = (DicomPrintConfig)lvi.Tag; PrinterSettingsForm psf = new PrinterSettingsForm(config); if (psf.ShowDialog(this) == DialogResult.OK) { SaveSettings(); } else { LoadSettings(); } }