鼠标单击edit box事件
没发现有这个事件,于是在PreTranslateMessage里拦截:
BOOL CDMFCView::PreTranslateMessage(MSG* pMsg)
{
// TODO: Add your specialized code here and/or call the base class
if (pMsg->hwnd == m_flow_wt_edit.m_hWnd && pMsg->message ==WM_LBUTTONDOWN)
{
。。。。。。。。。。。。。。。//响应事件
m_flow_rd_edit.SetFocus();
pMsg->hwnd = m_flow_rd_edit.m_hWnd;//这里如果不移开焦点,随便点其他控件也会触发事件(焦点在哪句柄就在哪?)
}
return CFormView::PreTranslateMessage(pMsg);
}