|
@@ -263,19 +263,19 @@ namespace OTSMeasureApp
|
|
|
if (IDC_COMBO_XRAYSCANMODE.Items.Count > 0)
|
|
|
IDC_COMBO_XRAYSCANMODE.SelectedIndex = 0;
|
|
|
this.IDC_COMBO_XRAYSCANMODE.SelectedIndexChanged += new System.EventHandler(this.IDC_COMBO_XRAYSCANMODE_SelectedIndexChanged);
|
|
|
- //是否使用X-ray
|
|
|
- IDC_COMBO_USINGXRAYS.Items.Clear();
|
|
|
- foreach (otsdataconst.OTS_USING_X_RAY enum_one in Enum.GetValues(typeof(otsdataconst.OTS_USING_X_RAY)))
|
|
|
- {
|
|
|
- ComboBoxItem cbi = new ComboBoxItem();
|
|
|
- cbi.Text = GetUSINGXRAYSIdString(enum_one);
|
|
|
- cbi.Value = (int)enum_one;
|
|
|
- IDC_COMBO_USINGXRAYS.Items.Add(cbi);
|
|
|
- }
|
|
|
- this.IDC_COMBO_USINGXRAYS.SelectedIndexChanged -= new System.EventHandler(this.IDC_COMBO_USINGXRAYS_SelectedIndexChanged);
|
|
|
- if (IDC_COMBO_USINGXRAYS.Items.Count > 0)
|
|
|
- IDC_COMBO_USINGXRAYS.SelectedIndex = 0;
|
|
|
- this.IDC_COMBO_USINGXRAYS.SelectedIndexChanged += new System.EventHandler(this.IDC_COMBO_USINGXRAYS_SelectedIndexChanged);
|
|
|
+ ////是否使用X-ray
|
|
|
+ //IDC_COMBO_USINGXRAYS.Items.Clear();
|
|
|
+ //foreach (otsdataconst.OTS_USING_X_RAY enum_one in Enum.GetValues(typeof(otsdataconst.OTS_USING_X_RAY)))
|
|
|
+ //{
|
|
|
+ // ComboBoxItem cbi = new ComboBoxItem();
|
|
|
+ // cbi.Text = GetUSINGXRAYSIdString(enum_one);
|
|
|
+ // cbi.Value = (int)enum_one;
|
|
|
+ // IDC_COMBO_USINGXRAYS.Items.Add(cbi);
|
|
|
+ //}
|
|
|
+ //this.IDC_COMBO_USINGXRAYS.SelectedIndexChanged -= new System.EventHandler(this.IDC_COMBO_USINGXRAYS_SelectedIndexChanged);
|
|
|
+ //if (IDC_COMBO_USINGXRAYS.Items.Count > 0)
|
|
|
+ // IDC_COMBO_USINGXRAYS.SelectedIndex = 0;
|
|
|
+ //this.IDC_COMBO_USINGXRAYS.SelectedIndexChanged += new System.EventHandler(this.IDC_COMBO_USINGXRAYS_SelectedIndexChanged);
|
|
|
//分析X-Ray精度
|
|
|
IDC_COMBO_ANALYXRAYSPEED.Items.Clear();
|
|
|
foreach (otsdataconst.OTS_IMAGE_SCANSPEED_OPTIONS enum_one in Enum.GetValues(typeof(otsdataconst.OTS_IMAGE_SCANSPEED_OPTIONS)))
|
|
@@ -659,15 +659,7 @@ namespace OTSMeasureApp
|
|
|
}
|
|
|
|
|
|
//是否使用电镜
|
|
|
- foreach (ComboBoxItem cbi in IDC_COMBO_USINGXRAYS.Items)
|
|
|
- {
|
|
|
- if (cbi.Value.ToString() != "")
|
|
|
- if (Convert.ToInt32(cbi.Value) == (int)m_cotsxrayprm.GetUsingXray())
|
|
|
- {
|
|
|
- IDC_COMBO_USINGXRAYS.SelectedItem = cbi;
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
+ IDC_USINGXRAY_LIB.Checked = m_cotsxrayprm.GetUsingXray();
|
|
|
|
|
|
//分析X-ray精度
|
|
|
foreach (ComboBoxItem cbi in IDC_COMBO_ANALYXRAYSPEED.Items)
|
|
@@ -844,9 +836,7 @@ namespace OTSMeasureApp
|
|
|
m_cotsxrayprm.SetScanMode((otsdataconst.OTS_X_RAY_SCAN_MODE)Convert.ToInt32(enum_xrayscanmode.Value));
|
|
|
|
|
|
//是否使用X-ray
|
|
|
- ComboBoxItem enum_usingxray = (ComboBoxItem)IDC_COMBO_USINGXRAYS.SelectedItem;
|
|
|
- bool usingxray = (int)(enum_usingxray.Value) == 0 ? true:false;//the combobox downitem is "True==0,false==1",so make a convertion here.
|
|
|
- m_cotsxrayprm.SetUsingXray(usingxray);
|
|
|
+ m_cotsxrayprm.SetUsingXray(IDC_USINGXRAY_LIB.Checked);
|
|
|
|
|
|
//分析X-ray精度
|
|
|
ComboBoxItem enum_analyxrayspeed = (ComboBoxItem)IDC_COMBO_ANALYXRAYSPEED.SelectedItem;
|
|
@@ -1269,14 +1259,6 @@ namespace OTSMeasureApp
|
|
|
IDC_COMBO_XRAYSCANMODE.SelectAll();
|
|
|
return false;
|
|
|
}
|
|
|
- if ("" == IDC_COMBO_USINGXRAYS.Text)
|
|
|
- {
|
|
|
- string message = table["message61"].ToString();
|
|
|
- MessageBox.Show(message, "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
|
|
|
- IDC_COMBO_USINGXRAYS.Focus();
|
|
|
- IDC_COMBO_USINGXRAYS.SelectAll();
|
|
|
- return false;
|
|
|
- }
|
|
|
if ("" == IDC_COMBO_ANALYXRAYSPEED.Text)
|
|
|
{
|
|
|
string message = table["message21"].ToString();
|