/// <summary> /// Displays the Database configuration form for the selected database type (Stats or Gamespy) /// </summary> /// <param name="Mode">The database type</param> /// <param name="Parent">The parent window to Dialog over</param> public static void ShowDatabaseSetupForm(DatabaseMode Mode, Form Parent = null) { // Try and get the active form if (Parent == null) { Parent = Form.ActiveForm; } using (DatabaseConfigForm F = new DatabaseConfigForm(Mode)) { if (Parent != null && Parent.IsHandleCreated && !Parent.InvokeRequired) { F.ShowDialog(Parent); } else { F.ShowDialog(); } } }
/// <summary> /// Displays the Database configuration form for the selected database type (Stats or Gamespy) /// </summary> /// <param name="Mode">The database type</param> /// <param name="Parent">The parent window to Dialog over</param> public static void ShowDatabaseSetupForm(DatabaseMode Mode, Form Parent = null) { // Try and get the active form if (Parent == null) Parent = Form.ActiveForm; using (DatabaseConfigForm F = new DatabaseConfigForm(Mode)) { if (Parent != null && Parent.IsHandleCreated && !Parent.InvokeRequired) F.ShowDialog(Parent); else F.ShowDialog(); } }