SDownload.Program.ShowSettings C# (CSharp) Method

ShowSettings() private method

Show the settings form, creating one of it doesn't already exist
private ShowSettings ( object sender, EventArgs eventArgs ) : void
sender object Not used
eventArgs System.EventArgs Not used
return void
        private void ShowSettings(object sender, EventArgs eventArgs)
        {
            // Only create a form if one doesn't already exist
            if (_settingsForm == null || _settingsForm.IsDisposed)
            {
                _settingsForm = new SettingsForm();
                _settingsForm.Closing += (o, args) => { _settingsForm = null; };
            }
            _settingsForm.Show();
        }