| | |
| | | #include "ViewRecipeProfileView.h" |
| | | #include "afxdialogex.h" |
| | | #include "Global_Define.h" |
| | | #include "DlgCoordinateConvert.h" |
| | | |
| | | // CViewRecipeProfileView 措拳 惑磊涝聪促. |
| | | |
| | |
| | | CDialogEx::DoDataExchange(pDX); |
| | | } |
| | | |
| | | |
| | | BEGIN_MESSAGE_MAP(CViewRecipeProfileView, CDialogEx) |
| | | ON_WM_SHOWWINDOW() |
| | | END_MESSAGE_MAP() |
| | | |
| | | BEGIN_EVENTSINK_MAP(CViewRecipeProfileView, CDialogEx) |
| | | |
| | | ON_EVENT(CViewRecipeProfileView, IDC_BTN_PROFILE_TEST_RUN, DISPID_CLICK, CViewRecipeProfileView::ClickChkButProfileTestRun, VTS_NONE) |
| | | ON_EVENT(CViewRecipeProfileView, IDC_BTN_PROFILE_COORDINATE_CONVERT, DISPID_CLICK, CViewRecipeProfileView::ClickChkButCoordinateConvert, VTS_NONE) |
| | | ON_EVENT(CViewRecipeProfileView, IDC_BTN_PROFILE_MAKECAD, DISPID_CLICK, CViewRecipeProfileView::ClickChkButMakeCAD, VTS_NONE) |
| | | ON_EVENT(CViewRecipeProfileView, IDC_BTN_PROFILE_APPLY, DISPID_CLICK, CViewRecipeProfileView::ClickChkButProfileApplay, VTS_NONE) |
| | | ON_EVENT(CViewRecipeProfileView, IDC_BTN_PROFILE_TEST_RUN, DISPID_CLICK, CViewRecipeProfileView::ClickChkButProfileTestRun, VTS_NONE) |
| | | |
| | | END_EVENTSINK_MAP() |
| | | |
| | | BOOL CViewRecipeProfileView::OnInitDialog() |
| | |
| | | } |
| | | |
| | | return CDialog::PreTranslateMessage(pMsg); |
| | | } |
| | | |
| | | void CViewRecipeProfileView::ClickChkButProfileTestRun() |
| | | { |
| | | if (m_pProfileProc == NULL) |
| | | return; |
| | | |
| | | CString str = _T("C:\\RCutProject\\Profile\\TEST5_B.prf"); |
| | | |
| | | m_pProfileProc->ReadProfileData(str); |
| | | |
| | | CPoint ptFirst, ptSecond; |
| | | |
| | | ptFirst = CPoint(2160, 32512); |
| | | ptSecond = CPoint(2186, 66030); |
| | | |
| | | //m_pProfileProc->RotateProfileData(ptFirst,ptSecond); |
| | | } |
| | | |
| | | void CViewRecipeProfileView::ClickChkButCoordinateConvert() |
| | | { |
| | | if (m_pProfileProc == NULL || m_pDlgRecipe == NULL) { |
| | | return; |
| | | } |
| | | |
| | | CDlgCoordinateConvert dlg; |
| | | dlg.SetRecipe(m_pDlgRecipe); |
| | | if (dlg.DoModal() == IDOK) { |
| | | g_pLog->DisplayMessage(_T("User applied coordinate conversion!")); |
| | | } |
| | | } |
| | | |
| | | void CViewRecipeProfileView::ClickChkButMakeCAD() |
| | |
| | | SetSlashText(GLOBAL_DEFINE::emHide, _T(""), RGB(0,0,0)); |
| | | } |
| | | |
| | | void CViewRecipeProfileView::ClickChkButProfileApplay() |
| | | { |
| | | UpdateData(TRUE); |
| | | } |
| | | |
| | | void CViewRecipeProfileView::OnShowWindow(BOOL bShow, UINT nStatus) |
| | | { |
| | |
| | | { |
| | | UpdateData(FALSE); |
| | | } |
| | | } |
| | | |
| | | void CViewRecipeProfileView::ClickChkButProfileApplay() |
| | | { |
| | | UpdateData(TRUE); |
| | | } |
| | | |
| | | void CViewRecipeProfileView::ClickChkButProfileTestRun() |
| | | { |
| | | if(m_pProfileProc == NULL) |
| | | return; |
| | | |
| | | CString str=_T("C:\\RCutProject\\Profile\\TEST5_B.prf"); |
| | | |
| | | m_pProfileProc->ReadProfileData(str); |
| | | |
| | | CPoint ptFirst,ptSecond; |
| | | |
| | | ptFirst = CPoint(2160,32512); |
| | | ptSecond = CPoint(2186,66030); |
| | | |
| | | //m_pProfileProc->RotateProfileData(ptFirst,ptSecond); |
| | | |
| | | } |
| | | |
| | | void CViewRecipeProfileView::SetRecipe(CHardwareSettings *pHW,CGlassRecipe *pRecipe) |