afx_msg void OnMDIActivate( BOOL bActivate, CWnd* pActivatedWnd, CWnd* pDeactivatedWnd );
bActivate
When the client window calls a child window's OnMDIActivate member function, bActivate is TRUE if the child is being activated and FALSE if it is being deactivated.
pActivatedWnd
When the application calls its MDI client window's OnMDIActivate member function, pActivatedWnd contains a pointer to the MDI child window to be activated. When received by an MDI child window, pActivatedWnd contains a pointer to the child window being activated. This pointer may be temporary, and should not be stored for later use.
pDeactivatedWnd
When received by an MDI child window, pDeactivatedWnd contains a pointer to the child window being deactivated. This pointer may be temporary, and should not be stored for later use.
An application calls the multiple document interface (MDI) CMDIFrameWnd::MDIActivate member function to activate a different MDI child window. The OnMDIActivate member function is called for the child window being deactivated and the child window being activated.
An MDI child window is activated independently of the MDI frame window. When the frame becomes active, the child window that was last activated with a OnMDIActivate call receives a WM_NCACTIVATE message to draw an active window frame and caption bar, but it does not receive another OnMDIActivate call.
This message-handler member function calls the Default member function. Override this member function in your derived class to handle the WM_MDIACTIVATE message.
CMDIFrameWnd::MDIGetActive, CMDIFrameWnd::MDINext, CMDIFrameWnd::MDIActivate, WM_MDIACTIVATE, CWnd::Default