public DialogResult ShowPreImportDialogs() { if (BeginWork != null) { BeginWork(this, new EventArgs()); } DialogResult result; if (!_regSEReader.LoadCompleted) { var progressIndicator = new ProgressIndicator(_regSEReader); _regSEReader.StartLoadTracks(); result = progressIndicator.ShowDialog(); if (result != DialogResult.OK) { if (EndWork != null) { EndWork(this, new EventArgs()); } return(result); } } using (var dlg = new JJConnectRegistratorSETrackSelector { DeviceReader = _regSEReader }) { result = dlg.ShowDialog(); if (result == DialogResult.OK) { _trackToImport = dlg.SelectedTrack; } dlg.Dispose(); } if (EndWork != null) { EndWork(this, new EventArgs()); } return(result); }
public DialogResult ShowPreImportDialogs() { if (BeginWork != null) BeginWork(this, new EventArgs()); DialogResult result; if (!_regSEReader.LoadCompleted) { var progressIndicator = new ProgressIndicator(_regSEReader); _regSEReader.StartLoadTracks(); result = progressIndicator.ShowDialog(); if (result != DialogResult.OK) { if (EndWork != null) EndWork(this, new EventArgs()); return result; } } using (var dlg = new JJConnectRegistratorSETrackSelector { DeviceReader = _regSEReader }) { result = dlg.ShowDialog(); if (result == DialogResult.OK) { _trackToImport = dlg.SelectedTrack; } dlg.Dispose(); } if (EndWork != null) EndWork(this, new EventArgs()); return result; }