How to enable or disable an event hander in MFC?
问题 I have searched the web a lot but couldn't find exactly what I want! suppose that I have a class derived from CWnd . In fact, it is the class COpenGLControl here in codeguru customized by me for my own purposes. the event handler for the WM_MOUSEMOVE button is written as follows: void COpenGLControl::OnMouseMove(UINT nFlags, CPoint point) { int diffX = (int)(point.x - m_fLastX); int diffY = (int)(point.y - m_fLastY); m_fLastX = (float)point.x; m_fLastY = (float)point.y; // Left mouse button