public void OnGetServiceSetting(ref CaliConfig cc) { cc.len = (byte)Marshal.SizeOf(typeof(CaliConfig)); cc.version = 0x1; cc.BaseColor = (byte)(this.m_sPrinterProperty.eColorOrder[this.m_ComboBoxBaseColor.SelectedIndex]); cc.YStepColor[0] = (byte)(this.m_sPrinterProperty.eColorOrder[this.comboBoxYStepColor1.SelectedIndex]); cc.YStepColor[1] = (byte)(this.m_sPrinterProperty.eColorOrder[this.comboBoxYStepColor2.SelectedIndex]); }
public void OnPrinterSettingChange(SPrinterSetting ss, CaliConfig cc) { int PassListNum = ss.sFrequencySetting.nPass; m_CheckedListBoxPass.Items.Clear(); string spass = ResString.GetDisplayPass(); for (int i = 0; i < PassListNum; i++) { string dispPass = (i + 1).ToString() + " " + spass; m_CheckedListBoxPass.Items.Add(dispPass); m_CheckedListBoxPass.SetItemChecked(i, true); } //CoreInterface.GetSeviceSetting(ref sSeviceSet); //OnServiceSettingChange(sSeviceSet,cc); //this.isDirty = false; }
public void OnServiceSettingChange(SSeviceSetting sSeviceSet, CaliConfig cc) { if (m_sPrinterProperty.EPSONLCD_DEFINED) { int i = 0; foreach (byte ce in m_sPrinterProperty.eColorOrder) { if (ce == cc.BaseColor) { UIPreference.SetSelectIndexAndClampWithMax(m_ComboBoxBaseColor, i); } if (ce == cc.YStepColor[0]) { UIPreference.SetSelectIndexAndClampWithMax(comboBoxYStepColor1, i); } if (ce == cc.YStepColor[1]) { UIPreference.SetSelectIndexAndClampWithMax(comboBoxYStepColor2, i); } i++; } } else { UIPreference.SetSelectIndexAndClampWithMax(m_ComboBoxBaseColor, sSeviceSet.nCalibrationHeadIndex); } if (sSeviceSet.Vsd2ToVsd3_ColorDeep >= 1 && sSeviceSet.Vsd2ToVsd3_ColorDeep <= 3) { UIPreference.SetSelectIndexAndClampWithMax(m_ComboBoxBit2Mode, sSeviceSet.Vsd2ToVsd3_ColorDeep - 1); } else { UIPreference.SetSelectIndexAndClampWithMax(m_ComboBoxBit2Mode, 0); } uint mask = 0x1; for (int j = 0; j < m_CheckedListBoxColor.Items.Count; j++) { if ((sSeviceSet.unColorMask & mask) == 0) { m_CheckedListBoxColor.SetItemChecked(j, true); } else { m_CheckedListBoxColor.SetItemChecked(j, false); } mask <<= 1; } mask = 0x1; for (int j = 0; j < m_CheckedListBoxPass.Items.Count; j++) { if ((sSeviceSet.unPassMask & mask) == 0) { m_CheckedListBoxPass.SetItemChecked(j, true); } else { m_CheckedListBoxPass.SetItemChecked(j, false); } mask <<= 1; } UIPreference.SetSelectIndexAndClampWithMax(m_ComboBoxSpeed, (int)sSeviceSet.Vsd2ToVsd3); }