This commit is contained in:
David Sparer
2018-09-30 13:19:35 -05:00
parent 0c95f178ca
commit ec80a5aa70
3 changed files with 12 additions and 1 deletions

View File

@@ -2,6 +2,7 @@
Fixes:
------
#1117: Duplicate panel created when "Reconnect on Startup" and "Create Empty Panel" settings enabled
#1115: Exception when changing from xml data storage to SQL
#1110: Pressing Delete button during connection rename attempts to delete the connection instead of the text
#1106: Inheritance does not work when parent has C# default type set

View File

@@ -184,7 +184,10 @@ namespace mRemoteNG.UI.Forms
var panelName = !string.IsNullOrEmpty(Settings.Default.StartUpPanelName)
? Settings.Default.StartUpPanelName
: Language.strNewPanel;
new PanelAdder().AddPanel(panelName);
var panelAdder = new PanelAdder();
if (!panelAdder.DoesPanelExist(panelName))
panelAdder.AddPanel(panelName);
}
}

View File

@@ -1,5 +1,6 @@
using System;
using System.Collections;
using System.Linq;
using System.Windows.Forms;
using mRemoteNG.App;
using mRemoteNG.Messages;
@@ -30,6 +31,12 @@ namespace mRemoteNG.UI.Panels
}
}
public bool DoesPanelExist(string panelName)
{
return Runtime.WindowList?.OfType<ConnectionWindow>().Any(w => w.TabText == panelName)
?? false;
}
private static void ShowConnectionWindow(ConnectionWindow connectionForm)
{
connectionForm.Show(FrmMain.Default.pnlDock, DockState.Document);