⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 listctrleditbox.cpp

📁 3D reconstruction, medical image processing from colons, using intel image processing for based clas
💻 CPP
字号:
// ListCtrlEditBox.cpp : implementation file//#include "stdafx.h"#include "fusion.h"#include "ListCtrlEditBox.h"#ifdef _DEBUG#define new DEBUG_NEW#undef THIS_FILEstatic char THIS_FILE[] = __FILE__;#endif/////////////////////////////////////////////////////////////////////////////// RxListCtrlEditBoxRxListCtrlEditBox::RxListCtrlEditBox(){}RxListCtrlEditBox::~RxListCtrlEditBox(){}BEGIN_MESSAGE_MAP(RxListCtrlEditBox, CEdit)	//{{AFX_MSG_MAP(RxListCtrlEditBox)	ON_WM_CREATE()	ON_WM_KILLFOCUS()	ON_WM_CHAR()	//}}AFX_MSG_MAPEND_MESSAGE_MAP()/////////////////////////////////////////////////////////////////////////////// RxListCtrlEditBox message handlersint RxListCtrlEditBox::OnCreate(LPCREATESTRUCT lpCreateStruct) {	if (CEdit::OnCreate(lpCreateStruct) == -1)		return -1;		SetWindowText(m_strText);	SetFont(GetParent()->GetFont(), FALSE);	SetFocus();	SetSel(0, -1);		return 0;}void RxListCtrlEditBox::OnKillFocus(CWnd* pNewWnd) {	CEdit::OnKillFocus(pNewWnd);		DestroyWindow();	}void RxListCtrlEditBox::PostNcDestroy() {	CEdit::PostNcDestroy();	delete this;}void RxListCtrlEditBox::OnChar(UINT nChar, UINT nRepCnt, UINT nFlags) {	if(nChar == VK_ESCAPE)	{		GetParent()->SetFocus();		return;	}	else if(nChar == VK_RETURN)	{		GetWindowText(m_strText);		SendMessageToParent();		return;	}		CEdit::OnChar(nChar, nRepCnt, nFlags);}/////////////////////////////////////////////////////////////////////////////void RxListCtrlEditBox::SetListCtrlInfo(int iRow, int iCol, LPCTSTR lpszText){	m_iRow = iRow;	m_iCol = iCol;	m_strText = lpszText;}void RxListCtrlEditBox::SendMessageToParent(){	NMLCEB_CTRL		nmlceb;	nmlceb.hdr.hwndFrom	= m_hWnd;	nmlceb.hdr.idFrom	= GetDlgCtrlID();	nmlceb.hdr.code		= LISTCTRL_CHANGED;	nmlceb.iRow			= m_iRow;	nmlceb.iCol			= m_iCol;	nmlceb.lpszText		= (LPCTSTR)m_strText;	CWnd* pOwner = GetOwner();	if (pOwner)		pOwner->SendMessage(WM_NOTIFY, nmlceb.hdr.idFrom, (LPARAM)&nmlceb);}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -