| | |
| | | { |
| | | m_pFirstView = new CCHImageView(this); |
| | | m_pSecondView = new CCHImageView(this); |
| | | /*< LYW 20211012 - #3671 ADD Start >*/ |
| | | m_pFirstAssistantView = new CCHImageView(this); |
| | | m_pSecondAssistantView = new CCHImageView(this); |
| | | /*< LYW 20211012 - #3671 ADD End >*/ |
| | | } |
| | | |
| | | CDlgAlign::~CDlgAlign() |
| | |
| | | delete m_pSecondView; |
| | | m_pSecondView = NULL; |
| | | } |
| | | /*< LYW 20211012 - #3671 ADD Start >*/ |
| | | if (m_pFirstAssistantView) |
| | | { |
| | | delete m_pFirstAssistantView; |
| | | m_pFirstAssistantView = NULL; |
| | | } |
| | | |
| | | if (m_pSecondAssistantView) |
| | | { |
| | | delete m_pSecondAssistantView; |
| | | m_pSecondAssistantView = NULL; |
| | | } |
| | | /*< LYW 20211012 - #3671 ADD End >*/ |
| | | } |
| | | |
| | | void CDlgAlign::DoDataExchange(CDataExchange* pDX) |
| | |
| | | { |
| | | m_pSecondView->Invalidate(TRUE); |
| | | } |
| | | /*< LYW 20211012 - #3671 ADD Start >*/ |
| | | else if (nIdx == 2 && m_pFirstAssistantView->LoadImage(strFilepath)) |
| | | { |
| | | m_pFirstAssistantView->Invalidate(TRUE); |
| | | } |
| | | else if (nIdx == 3 && m_pSecondAssistantView->LoadImage(strFilepath)) |
| | | { |
| | | m_pSecondAssistantView->Invalidate(TRUE); |
| | | } |
| | | /*< LYW 20211012 - #3671 ADD End >*/ |
| | | |
| | | |
| | | m_ctrlGridAlignImageInfo.SetItemText(nIdx, 1, strFilename); |
| | |
| | | CRect rect; |
| | | rect.left = 10; |
| | | rect.top = 550; |
| | | rect.right = rect.left + 232; |
| | | rect.bottom = rect.top + 232; |
| | | rect.right = rect.left + 150; |
| | | rect.bottom = rect.top + 150; |
| | | |
| | | m_pFirstView->Create(NULL, NULL, WS_CHILD | WS_VISIBLE | LBS_NOTIFY , rect, this, 0); |
| | | m_pFirstView->SetDrawType(DrawFit); |
| | |
| | | if (m_pSecondView) |
| | | { |
| | | CRect rect; |
| | | rect.left = 244; |
| | | rect.left = 161; |
| | | rect.top = 550; |
| | | rect.right = rect.left + 232; |
| | | rect.bottom = rect.top + 232; |
| | | rect.right = rect.left + 150; |
| | | rect.bottom = rect.top + 150; |
| | | |
| | | m_pSecondView->Create(NULL, NULL, WS_CHILD | WS_VISIBLE | LBS_NOTIFY , rect, this, 0); |
| | | m_pSecondView->SetDrawType(DrawFit); |
| | | m_pSecondView->SetViewName(_T("Second")); |
| | | m_pSecondView->ShowWindow(SW_SHOW); |
| | | } |
| | | |
| | | /*< LYW 20211012 - #3671 ADD Start >*/ |
| | | if (m_pFirstAssistantView) |
| | | { |
| | | CRect rect; |
| | | rect.left = 10; |
| | | rect.top = 701; |
| | | rect.right = rect.left + 150; |
| | | rect.bottom = rect.top + 150; |
| | | |
| | | m_pFirstAssistantView->Create(NULL, NULL, WS_CHILD | WS_VISIBLE | LBS_NOTIFY, rect, this, 0); |
| | | m_pFirstAssistantView->SetDrawType(DrawFit); |
| | | m_pFirstAssistantView->SetViewName(_T("FirstAssistant")); |
| | | m_pFirstAssistantView->ShowWindow(SW_SHOW); |
| | | } |
| | | |
| | | if (m_pSecondAssistantView) |
| | | { |
| | | CRect rect; |
| | | rect.left = 161; |
| | | rect.top = 701; |
| | | rect.right = rect.left + 150; |
| | | rect.bottom = rect.top + 150; |
| | | |
| | | m_pSecondAssistantView->Create(NULL, NULL, WS_CHILD | WS_VISIBLE | LBS_NOTIFY, rect, this, 0); |
| | | m_pSecondAssistantView->SetDrawType(DrawFit); |
| | | m_pSecondAssistantView->SetViewName(_T("SecondAssistant")); |
| | | m_pSecondAssistantView->ShowWindow(SW_SHOW); |
| | | } |
| | | /*< LYW 20211012 - #3671 ADD End >*/ |
| | | |
| | | return TRUE; // return TRUE unless you set the focus to a control |
| | | // 예외: OCX 속성 페이지는 FALSE를 반환해야 합니다. |
| | |
| | | nRowIdx++; |
| | | pRcpRsAlignManager->GetRsRcpAlignInfo()->m_strSecondImageFile = m_ctrlGridAlignImageInfo.GetItemText(nRowIdx, nColIdx); |
| | | nRowIdx++; |
| | | /*< LYW 20211012 - #3671 ADD Start >*/ |
| | | pRcpRsAlignManager->GetRsRcpAlignInfo()->m_strFirstAssistantImageFile = m_ctrlGridAlignImageInfo.GetItemText(nRowIdx, nColIdx); |
| | | nRowIdx++; |
| | | pRcpRsAlignManager->GetRsRcpAlignInfo()->m_strSecondAssistantImageFile = m_ctrlGridAlignImageInfo.GetItemText(nRowIdx, nColIdx); |
| | | nRowIdx++; |
| | | /*< LYW 20211012 - #3671 ADD End >*/ |
| | | |
| | | strItemText = m_ctrlGridAlignImageInfo.GetItemText(nRowIdx, nColIdx); |
| | | pRcpRsAlignManager->GetRsRcpAlignInfo()->m_dMatchingRate = _tcstod(strItemText, NULL); |
| | |
| | | Item.strText = strTemp; |
| | | m_ctrlGridAlignImageInfo.SetItem(&Item); |
| | | |
| | | /*< LYW 20211012 - #3671 ADD Start >*/ |
| | | nRowIdx++; |
| | | Item.row = nRowIdx; |
| | | Item.col = nColIdx; |
| | | strTemp.Format(_T("1st Assist Mark")); |
| | | Item.strText = strTemp; |
| | | m_ctrlGridAlignImageInfo.SetItem(&Item); |
| | | |
| | | nRowIdx++; |
| | | Item.row = nRowIdx; |
| | | Item.col = nColIdx; |
| | | strTemp.Format(_T("2nd Assist Mark")); |
| | | Item.strText = strTemp; |
| | | m_ctrlGridAlignImageInfo.SetItem(&Item); |
| | | /*< LYW 20211012 - #3671 ADD End >*/ |
| | | |
| | | nRowIdx++; |
| | | Item.row = nRowIdx; |
| | | Item.col = nColIdx; |
| | |
| | | m_ctrlGridAlignImageInfo.SetCellType(nRowIdx, nColIdx, RUNTIME_CLASS(CGridCellButton)); |
| | | pCellButton = (CGridCellButton*)m_ctrlGridAlignImageInfo.GetCell(nRowIdx, nColIdx); |
| | | pCellButton->SetText(_T("Browser")); |
| | | |
| | | /*< LYW 20211012 - #3671 ADD Start >*/ |
| | | // first Assistant |
| | | nRowIdx = 2; |
| | | nColIdx = 1; |
| | | strItemText = pRcpRsAlignManager->GetRsRcpAlignInfo()->m_strFirstAssistantImageFile; |
| | | m_ctrlGridAlignImageInfo.SetItemText(nRowIdx, nColIdx, strItemText); |
| | | |
| | | strFilename = ALIGN_IMAGE_PATH; |
| | | strFilename = strFilename + _T("\\") + strItemText; |
| | | m_pFirstAssistantView->LoadImage(strFilename); |
| | | /*m_pFirstView->Invalidate(TRUE);*/ |
| | | |
| | | nColIdx = 2; |
| | | m_ctrlGridAlignImageInfo.SetCellType(nRowIdx, nColIdx, RUNTIME_CLASS(CGridCellButton)); |
| | | pCellButton = (CGridCellButton*)m_ctrlGridAlignImageInfo.GetCell(nRowIdx, nColIdx); |
| | | pCellButton->SetText(_T("Browser")); |
| | | |
| | | // second Assistant |
| | | nRowIdx = 3; |
| | | nColIdx = 1; |
| | | strItemText = pRcpRsAlignManager->GetRsRcpAlignInfo()->m_strSecondAssistantImageFile; |
| | | m_ctrlGridAlignImageInfo.SetItemText(nRowIdx, nColIdx, strItemText); |
| | | strFilename = ALIGN_IMAGE_PATH; |
| | | strFilename = strFilename + _T("\\") + strItemText; |
| | | m_pSecondAssistantView->LoadImage(strFilename); |
| | | //m_pSecondView->Invalidate(TRUE); |
| | | |
| | | nColIdx = 2; |
| | | m_ctrlGridAlignImageInfo.SetCellType(nRowIdx, nColIdx, RUNTIME_CLASS(CGridCellButton)); |
| | | pCellButton = (CGridCellButton*)m_ctrlGridAlignImageInfo.GetCell(nRowIdx, nColIdx); |
| | | pCellButton->SetText(_T("Browser")); |
| | | /*< LYW 20211012 - #3671 ADD End >*/ |
| | | // |
| | | |
| | | nRowIdx = 2; |
| | | nRowIdx = 4; |
| | | nColIdx = 1; |
| | | strItemText.Format(_T("%.3lf"), pRcpRsAlignManager->GetRsRcpAlignInfo()->m_dMatchingRate); |
| | | m_ctrlGridAlignImageInfo.SetItemText(nRowIdx, nColIdx, strItemText); |
| | | |
| | | // |
| | | nRowIdx = 3; |
| | | nRowIdx = 5; |
| | | nColIdx = 1; |
| | | strItemText = pRcpRsAlignManager->GetRsRcpAlignInfo()->m_strTotalPitchImageFile; |
| | | m_ctrlGridAlignImageInfo.SetItemText(nRowIdx, nColIdx, strItemText); |