SDC C-Project CF Review 프로그램
LYW
2021-09-23 c08b701c90c8998b241c82638d5c488e03238214
ReviewSystem/ReviewSystem/DlgSelfDiagnosis_Wsi.cpp
@@ -32,26 +32,24 @@
   DDX_Control(pDX, IDC_EDIT_WSI_RTB_01, m_ctrlWsiRtb01);
   DDX_Control(pDX, IDC_BUTTON_SIMULATION, m_btSimulation);
   DDX_Text(pDX, IDC_EDIT_WSI_FIRST_STANDARD, m_editWSIFirstStandard);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT1, m_editWSIHeight1);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT2, m_editWSIHeight2);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT3, m_editWSIHeight3);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT4, m_editWSIHeight4);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT5, m_editWSIHeight5);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT6, m_editWSIHeight6);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT7, m_editWSIHeight7);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT8, m_editWSIHeight8);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT9, m_editWSIHeight9);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT10, m_editWSIHeight10);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT11, m_editWSIHeight11);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT12, m_editWSIHeight12);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT13, m_editWSIHeight13);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT14, m_editWSIHeight14);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT15, m_editWSIHeight15);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT16, m_editWSIHeight16);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT17, m_editWSIHeight17);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT18, m_editWSIHeight18);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT19, m_editWSIHeight19);
   DDX_Control(pDX, IDC_EDIT_WSI_HEIGHT20, m_editWSIHeight20);
   DDX_Control(pDX, IDC_LIST_WSI_DIAGNOSIS_RESULT, m_ListWSIResult);
}
BOOL CDlgSelfDiagnosis_Wsi::OnInitDialog()
{
   CDialogEx::OnInitDialog();
   m_ListWSIResult.SetExtendedStyle(LVS_EX_FULLROWSELECT | LVS_EX_GRIDLINES);
   m_ListWSIResult.InsertColumn(0, _T("Index"), LVCFMT_CENTER, 70);
   m_ListWSIResult.InsertColumn(1, _T("Left Module"), LVCFMT_CENTER, 100);
   m_ListWSIResult.InsertColumn(2, _T("Right Module"), LVCFMT_CENTER, 100);
   m_ListWSIResult.SetRedraw(TRUE);
   // TODO:  여기에 추가 초기화 작업을 추가합니다.
   return TRUE;  // return TRUE unless you set the focus to a control
              // 예외: OCX 속성 페이지는 FALSE를 반환해야 합니다.
}
@@ -67,9 +65,10 @@
void CDlgSelfDiagnosis_Wsi::OnBnClickedButtonSimulation()
{
   if (m_pDiagnosisManager == NULL) return;
   //#3514_LYW_CF AOI Review 자가진단 기능 개선_START
   /*< LYW 20210719 : #3517 ADD Start >*/
   if (m_pDiagnosisManager->CheckManualMode() == FALSE)
   {
      CString strMessage;
@@ -80,7 +79,7 @@
         return;
      }
   }
   //#3514_LYW_CF AOI Review 자가진단 기능 개선_END
   /*< LYW 20210719 : #3517 ADD End >*/
   //GetDialogControls();
@@ -135,65 +134,21 @@
   m_ctrlWsiRtb00.SetWindowTextA(strRTB00);
   m_ctrlWsiRtb01.SetWindowTextA(strRTB01);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[0]);
   m_editWSIHeight1.SetWindowTextA(strDiagnosisHeight);
   for (int i = 0; i < 10; i++)
   {
      int nRow = i + 1;
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[1]);
   m_editWSIHeight2.SetWindowTextA(strDiagnosisHeight);
      strDiagnosisHeight.Format(_T("%d"), nRow);
      m_ListWSIResult.InsertItem(nRow, strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[2]);
   m_editWSIHeight3.SetWindowTextA(strDiagnosisHeight);
      strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[i]);
      m_ListWSIResult.SetItemText(nRow, 1, strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[3]);
   m_editWSIHeight4.SetWindowTextA(strDiagnosisHeight);
      strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[i+10]);
      m_ListWSIResult.SetItemText(nRow, 2, strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[4]);
   m_editWSIHeight5.SetWindowTextA(strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[5]);
   m_editWSIHeight6.SetWindowTextA(strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[6]);
   m_editWSIHeight7.SetWindowTextA(strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[7]);
   m_editWSIHeight8.SetWindowTextA(strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[8]);
   m_editWSIHeight9.SetWindowTextA(strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[9]);
   m_editWSIHeight10.SetWindowTextA(strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[10]);
   m_editWSIHeight11.SetWindowTextA(strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[11]);
   m_editWSIHeight12.SetWindowTextA(strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[12]);
   m_editWSIHeight13.SetWindowTextA(strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[13]);
   m_editWSIHeight14.SetWindowTextA(strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[14]);
   m_editWSIHeight15.SetWindowTextA(strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[15]);
   m_editWSIHeight16.SetWindowTextA(strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[16]);
   m_editWSIHeight17.SetWindowTextA(strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[17]);
   m_editWSIHeight18.SetWindowTextA(strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[18]);
   m_editWSIHeight19.SetWindowTextA(strDiagnosisHeight);
   strDiagnosisHeight.Format(_T("%d"), dDiagnosisHeight[19]);
   m_editWSIHeight20.SetWindowTextA(strDiagnosisHeight);
      m_ListWSIResult.EnsureVisible(nRow, FALSE);
   }
   
}
@@ -226,6 +181,7 @@
   double nRTB00 = dRbt00;
   double nRTB01 = dRbt01;
   CString strDiagnosisHeight;
   CString strACC00, strACC01;
   CString strRTB00, strRTB01;
   strACC00.Format(_T("%f"),nACC00);
@@ -242,6 +198,36 @@
      m_ctrlWsiRtb01.SetWindowTextA(strRTB01);
   }
   double dDiagnosisHeightleft[10];
   double dDiagnosisHeightRight[10];
   for (int i = 0; i < 10; i++)
   {
      dDiagnosisHeightleft[i] = m_pDiagnosisManager->GetDiagnosisResult_Wsi(0)->GetDiagnosisHeight(i);
   }
   for (int i = 0; i < 10; i++)
   {
      dDiagnosisHeightRight[i] = m_pDiagnosisManager->GetDiagnosisResult_Wsi(1)->GetDiagnosisHeight(i);
   }
   m_ListWSIResult.DeleteAllItems();
   for (int i = 0; i < 10; i++)
   {
         int nRow = i;
         strDiagnosisHeight.Format(_T("%d"), nRow + 1);
         m_ListWSIResult.InsertItem(nRow, strDiagnosisHeight);
         strDiagnosisHeight.Format(_T("%.3f"), dDiagnosisHeightleft[i]);
         m_ListWSIResult.SetItemText(nRow, 1, strDiagnosisHeight);
         strDiagnosisHeight.Format(_T("%.3f"), dDiagnosisHeightRight[i]);
         m_ListWSIResult.SetItemText(nRow, 2, strDiagnosisHeight);
         m_ListWSIResult.EnsureVisible(nRow, FALSE);
   }
}
@@ -270,3 +256,4 @@
   // TODO:  여기에 컨트롤 알림 처리기 코드를 추가합니다.
}