调整校正数据显示崩溃问题
This commit is contained in:
parent
15361bf545
commit
debf85dd63
|
@ -195,7 +195,7 @@ BOOL CHuaGoCorrectDlg::OnInitDialog()
|
|||
s_minute = "00";
|
||||
s_second = "00";
|
||||
UpdateData(FALSE);
|
||||
|
||||
((CEdit*)(m_A3dlg.GetDlgItem(IDC_LSTFLATINFO)))->SetLimitText(0xffffffff);
|
||||
bool ret = RefreshUSBList();
|
||||
if (ret)
|
||||
{
|
||||
|
@ -424,13 +424,16 @@ void CHuaGoCorrectDlg::OnBnClickedBtnFlat()
|
|||
USES_CONVERSION;
|
||||
std::string c_str = StringToUtf(info);
|
||||
CString pWideChar = A2T(c_str.c_str());
|
||||
CString oldinfo;
|
||||
UpdateData(FALSE);
|
||||
((CEdit*)(m_A3dlg.GetDlgItem(IDC_LSTFLATINFO)))->GetWindowText(oldinfo);
|
||||
oldinfo += pWideChar;
|
||||
((CEdit*)(m_A3dlg.GetDlgItem(IDC_LSTFLATINFO)))->SetWindowText(oldinfo);
|
||||
//CString oldinfo;
|
||||
//UpdateData(FALSE);
|
||||
//((CEdit*)(m_A3dlg.GetDlgItem(IDC_LSTFLATINFO)))->GetWindowText(oldinfo);
|
||||
//oldinfo += pWideChar;
|
||||
//((CEdit*)(m_A3dlg.GetDlgItem(IDC_LSTFLATINFO)))->SetWindowText(oldinfo);
|
||||
auto edit = ((CEdit*)(m_A3dlg.GetDlgItem(IDC_LSTFLATINFO)));
|
||||
edit->LineScroll(edit->GetLineCount());
|
||||
assert(edit && edit->GetSafeHwnd());
|
||||
edit->SetSel(edit->GetWindowTextLengthW(), edit->GetWindowTextLengthW());
|
||||
edit->ReplaceSel(pWideChar);
|
||||
//edit->LineScroll(edit->GetLineCount());
|
||||
};
|
||||
m_drv->SetFlatCallback(flatcall);
|
||||
m_drv->StartFlat(((CButton*)GetDlgItem(IDC_CKBCORRECTMODE))->GetCheck());
|
||||
|
|
Loading…
Reference in New Issue