LS.iPerlCommunicationsFormCheckBoxes -> OptoHeadsEnabled, MainWnd.optoHeadsToolStripMenuItem (+ visibility)
This commit is contained in:
parent
674dde8d74
commit
61ecb23294
@ -681,7 +681,7 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication
|
||||
TBF.LocalSettings ls = Program.LocalSettings;
|
||||
Left = (ls.iPerlCommunicationsFormLeft != 0) ? ls.iPerlCommunicationsFormLeft : 150;
|
||||
Top = (ls.iPerlCommunicationsFormTop != 0) ? ls.iPerlCommunicationsFormTop : 150;
|
||||
if (ls.iPerlCommunicationsFormCheckboxes != 0) SetCheckBoxStates(ls.iPerlCommunicationsFormCheckboxes);
|
||||
if (ls.OptoHeadsEnabled != 0) SetCheckBoxStates(ls.OptoHeadsEnabled);
|
||||
|
||||
if (!checkBoxesEditMode)
|
||||
{
|
||||
@ -728,12 +728,12 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication
|
||||
long checkboxStates = GetCheckBoxStates();
|
||||
if (Program.LocalSettings.iPerlCommunicationsFormLeft != Location.X ||
|
||||
Program.LocalSettings.iPerlCommunicationsFormTop != Location.Y ||
|
||||
Program.LocalSettings.iPerlCommunicationsFormCheckboxes != checkboxStates)
|
||||
Program.LocalSettings.OptoHeadsEnabled != checkboxStates)
|
||||
{
|
||||
/// Update local settings
|
||||
Program.LocalSettings.iPerlCommunicationsFormLeft = Location.X;
|
||||
Program.LocalSettings.iPerlCommunicationsFormTop = Location.Y;
|
||||
Program.LocalSettings.iPerlCommunicationsFormCheckboxes = checkboxStates;
|
||||
Program.LocalSettings.OptoHeadsEnabled = checkboxStates;
|
||||
Program.LocalSettings.Save();
|
||||
}
|
||||
|
||||
@ -2861,7 +2861,7 @@ namespace TBF.BenchControl.TestMethods.iPerlCommunication
|
||||
|
||||
private void saveButton_Click(object sender, EventArgs e)
|
||||
{
|
||||
Program.LocalSettings.iPerlCommunicationsFormCheckboxes = GetCheckBoxStates();
|
||||
Program.LocalSettings.OptoHeadsEnabled = GetCheckBoxStates();
|
||||
DialogResult = DialogResult.OK;
|
||||
Close();
|
||||
}
|
||||
|
||||
@ -205,7 +205,12 @@ namespace TBF
|
||||
/// iPerlCommunicationsForm
|
||||
public int iPerlCommunicationsFormLeft;
|
||||
public int iPerlCommunicationsFormTop;
|
||||
public long iPerlCommunicationsFormCheckboxes; /// Bit field with iPerlCommunicationForm checkboxes states
|
||||
|
||||
/// S640CommForm
|
||||
public int S640CommFormLeft;
|
||||
public int S640CommFormTop;
|
||||
///
|
||||
public long OptoHeadsEnabled; /// Bit field with opto-head enabled states, used by iPerlCommunicationForm and S640CommForm
|
||||
|
||||
/// Serial numbers
|
||||
public string[] LastSNTexts;
|
||||
|
||||
18
TBF/Resources/Strings.Designer.cs
generated
18
TBF/Resources/Strings.Designer.cs
generated
@ -798,6 +798,15 @@ namespace TBF.Resources {
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Clear counters.
|
||||
/// </summary>
|
||||
internal static string Clear_counters {
|
||||
get {
|
||||
return ResourceManager.GetString("Clear_counters", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Clear results.
|
||||
/// </summary>
|
||||
@ -3300,6 +3309,15 @@ namespace TBF.Resources {
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Optical heads.
|
||||
/// </summary>
|
||||
internal static string Optical_heads {
|
||||
get {
|
||||
return ResourceManager.GetString("Optical_heads", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Other.
|
||||
/// </summary>
|
||||
|
||||
@ -2263,4 +2263,10 @@
|
||||
<data name="Writing_to_the_production_tracing_DB_failed" xml:space="preserve">
|
||||
<value>Writing to the production tracing DB failed</value>
|
||||
</data>
|
||||
<data name="Optical_heads" xml:space="preserve">
|
||||
<value>Optical heads</value>
|
||||
</data>
|
||||
<data name="Clear_counters" xml:space="preserve">
|
||||
<value>Clear counters</value>
|
||||
</data>
|
||||
</root>
|
||||
12
TBF/UI/MainWnd.Designer.cs
generated
12
TBF/UI/MainWnd.Designer.cs
generated
@ -97,7 +97,7 @@ namespace TBF.UI
|
||||
this.backUpResultsTSMItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.passwdTSMItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.upgradeTSMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.iPerlHeadsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.optoHeadsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.clearCountersToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.helpTSMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.aboutTSMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
@ -525,7 +525,7 @@ namespace TBF.UI
|
||||
this.backUpTSMItem,
|
||||
this.passwdTSMItem,
|
||||
this.upgradeTSMenuItem,
|
||||
this.iPerlHeadsToolStripMenuItem,
|
||||
this.optoHeadsToolStripMenuItem,
|
||||
this.clearCountersToolStripMenuItem});
|
||||
this.settingsTSMenuItem.Name = "settingsTSMenuItem";
|
||||
resources.ApplyResources(this.settingsTSMenuItem, "settingsTSMenuItem");
|
||||
@ -582,9 +582,9 @@ namespace TBF.UI
|
||||
//
|
||||
// iPerlHeadsToolStripMenuItem
|
||||
//
|
||||
this.iPerlHeadsToolStripMenuItem.Name = "iPerlHeadsToolStripMenuItem";
|
||||
resources.ApplyResources(this.iPerlHeadsToolStripMenuItem, "iPerlHeadsToolStripMenuItem");
|
||||
this.iPerlHeadsToolStripMenuItem.Click += new System.EventHandler(this.iPerlHeadsToolStripMenuItem_Click);
|
||||
this.optoHeadsToolStripMenuItem.Name = "iPerlHeadsToolStripMenuItem";
|
||||
resources.ApplyResources(this.optoHeadsToolStripMenuItem, "iPerlHeadsToolStripMenuItem");
|
||||
this.optoHeadsToolStripMenuItem.Click += new System.EventHandler(this.optoHeadsToolStripMenuItem_Click);
|
||||
//
|
||||
// clearCountersToolStripMenuItem
|
||||
//
|
||||
@ -798,7 +798,7 @@ namespace TBF.UI
|
||||
private System.Windows.Forms.ToolStripMenuItem upgradeTSMenuItem;
|
||||
private System.Windows.Forms.TabPage graphsTabPage;
|
||||
private TBF.UI.Graphs.GraphsTabPageCtrl graphsTabPageCtrl;
|
||||
private System.Windows.Forms.ToolStripMenuItem iPerlHeadsToolStripMenuItem;
|
||||
private System.Windows.Forms.ToolStripMenuItem optoHeadsToolStripMenuItem;
|
||||
private System.Windows.Forms.ToolStripMenuItem clearCountersToolStripMenuItem;
|
||||
private System.Windows.Forms.ToolStripMenuItem backUpTSMItem;
|
||||
private System.Windows.Forms.ToolStripMenuItem backUpConfigTSMItem;
|
||||
|
||||
@ -103,6 +103,8 @@ namespace TBF.UI
|
||||
eventLogsTSMenuItem.Text = Strings.Event_logs;
|
||||
calendarTSMenuItem.Text = Strings.Calendar;
|
||||
settingsTSMenuItem.Text = Strings.Settings;
|
||||
optoHeadsToolStripMenuItem.Text = Strings.Optical_heads;
|
||||
clearCountersToolStripMenuItem.Text = Strings.Clear_counters;
|
||||
helpTSMenuItem.Text = Strings.Help;
|
||||
#if CAMERA
|
||||
/// Add 'Camera' menu item
|
||||
@ -116,12 +118,8 @@ namespace TBF.UI
|
||||
#endif
|
||||
UpdateMenuItemsVisibility();
|
||||
|
||||
#if IPERL
|
||||
iPerlHeadsToolStripMenuItem.Visible = true;
|
||||
iPerlHeadsToolStripMenuItem.Enabled = false;
|
||||
#else
|
||||
iPerlHeadsToolStripMenuItem.Visible = false;
|
||||
#endif
|
||||
optoHeadsToolStripMenuItem.Visible = true;
|
||||
optoHeadsToolStripMenuItem.Enabled = false;
|
||||
|
||||
IsShutdownDisabled = true;
|
||||
IsShutdownPCAfterClosingTbf = false;
|
||||
@ -440,7 +438,7 @@ namespace TBF.UI
|
||||
}
|
||||
|
||||
procedureComboBox.Enabled = ((args.Flags & ButtonsEtc.ProcedureCmbBoxEn) != 0);
|
||||
iPerlHeadsToolStripMenuItem.Enabled = ((args.Flags & ButtonsEtc.ProcedureCmbBoxEn) != 0);
|
||||
optoHeadsToolStripMenuItem.Enabled = ((args.Flags & ButtonsEtc.ProcedureCmbBoxEn) != 0);
|
||||
|
||||
if (procedureComboBox.Enabled && ProceduresUpdated)
|
||||
{
|
||||
@ -825,7 +823,7 @@ namespace TBF.UI
|
||||
new TBF.UI.Settings.UpgradeSelectionDlg().ShowDialog();
|
||||
}
|
||||
|
||||
private void iPerlHeadsToolStripMenuItem_Click(object sender, EventArgs e)
|
||||
private void optoHeadsToolStripMenuItem_Click(object sender, EventArgs e)
|
||||
{
|
||||
new BenchControl.TestMethods.iPerlCommunication.iPerlCommunicationForm(true).ShowDialog();
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user