From 4ed7fc8447d202e21ef9907e2aac63ef6fcbf301 Mon Sep 17 00:00:00 2001 From: zxd <zxdvslxy@gmail.com> Date: 星期二, 17 十月 2023 12:33:23 +0800 Subject: [PATCH] 提交图码转换部分修改: 1.基本图形转换 2.ANS\ORS\PSHS\POPS命令的处理 3.重构了转换方法,命名为CMTerm1View::ScanLDSCells2();同时将翻译单独提出为方法CMTerm1View::Translate2Prog() 4.快捷键的添加绑定 5.其他相关方法修改,Insert,Delete,FocusChg…… 6.其他关联修改 --- MTerm2/MTerm2View.cpp | 38 +++++++++++++++++++++++++++++++++----- 1 files changed, 33 insertions(+), 5 deletions(-) diff --git a/MTerm2/MTerm2View.cpp b/MTerm2/MTerm2View.cpp index 681f6d3..ac169e9 100644 --- a/MTerm2/MTerm2View.cpp +++ b/MTerm2/MTerm2View.cpp @@ -1446,18 +1446,45 @@ Cells[m_FocusRow][j].bLeftLineDn = 1; } } + // 褰撳墠琛� 鍔犲叆 瑙︾偣 - m_FocusCol; - Cells[m_FocusRow][0].nType= typeNO; - Cells[m_FocusRow][0].nDataType = KLCoilTypeX; - Cells[m_FocusRow][0].nDataAddr = 15; - Cells[m_FocusRow][0].sCoilName = "ABCDEFG"; +// m_FocusCol; +// Cells[m_FocusRow][0].nType= typeNO; +// Cells[m_FocusRow][0].nDataType = KLCoilTypeX; +// Cells[m_FocusRow][0].nDataAddr = 15; +// Cells[m_FocusRow][0].sCoilName = "ABCDEFG"; m_bModified = 1; needReDraw = 1; this->RedrawWindow(); } +int FindTypeIndex(CString str[], CString strType, int num) +{ + for (int i = 0;i < num;i++) + { + if (strType == str[i]) + { + return i; + } + } + return -1; +} +void CMTerm2View::GetIncToView(stCell cell1) //**************************************************************************************************// +{ + + + Cells[m_FocusRow][m_FocusCol] = cell1; + + m_bModified = 1; + needReDraw = 1; + m_FocusCol += 1; + if (m_FocusCol >= 16) + { m_FocusCol = 0;m_FocusRow += 1; } + + this->RedrawWindow(); + +} void CMTerm2View::OnUpdateInsertBlankLine(CCmdUI *pCmdUI) { // TODO: 鍦ㄦ娣诲姞鍛戒护鏇存柊鐢ㄦ埛鐣岄潰澶勭悊绋嬪簭浠g爜 @@ -2730,3 +2757,4 @@ } return 0; } + -- Gitblit v1.9.1