Cleanup and comment
This commit is contained in:
parent
35815fe78a
commit
8dc45484b0
@ -65,17 +65,17 @@ namespace TBF.UI.Bench.Components
|
||||
if (ComponentCfgCtrl != null)
|
||||
{
|
||||
splitContainer.Panel1.Controls.Add((UserControl)ComponentCfgCtrl);
|
||||
}
|
||||
|
||||
if ((ComponentCfgCtrl != null) && ComponentCfgCtrl.ShowMore)
|
||||
{
|
||||
sharedButtons.OptionalButtons = SharedButtons.Buttons.More;
|
||||
}
|
||||
if (ComponentCfgCtrl.ShowMore)
|
||||
{
|
||||
sharedButtons.OptionalButtons = SharedButtons.Buttons.More;
|
||||
}
|
||||
|
||||
if (UnlockAfterStart)
|
||||
{
|
||||
sharedButtons.UnlockButtons();
|
||||
ComponentCfgCtrl.Unlock();
|
||||
if (UnlockAfterStart)
|
||||
{
|
||||
sharedButtons.UnlockButtons();
|
||||
ComponentCfgCtrl.Unlock();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -414,7 +414,10 @@ namespace TBF.UI.Bench.Components
|
||||
IComponentCfg cfg = factory.DefaultConfig();
|
||||
if (selectComponentTypeDlg.SelectedScriptName == null)
|
||||
{
|
||||
IComponentCfgCtrl cfgControl = cfg.GetControl();
|
||||
///
|
||||
/// Create a single component of the selected type
|
||||
///
|
||||
IComponentCfgCtrl cfgControl = cfg.GetControl();
|
||||
cfgControl.Config = cfg;
|
||||
cfgControl.Config.ItemNr = (cmpntEntities.Count > 0) ? (cmpntEntities[cmpntEntities.Count - 1].ItemNr + 1) : 1;
|
||||
|
||||
@ -430,7 +433,10 @@ namespace TBF.UI.Bench.Components
|
||||
}
|
||||
else
|
||||
{
|
||||
using (TextReader reader = new StreamReader(selectComponentTypeDlg.SelectedScriptName))
|
||||
///
|
||||
/// Create more components, read their names and other properties from a file
|
||||
///
|
||||
using (TextReader reader = new StreamReader(selectComponentTypeDlg.SelectedScriptName))
|
||||
{
|
||||
int zeroBasedIdx = 0;
|
||||
string line = reader.ReadLine();
|
||||
|
||||
Loading…
Reference in New Issue
Block a user