Have been engaged in Unix programming, recently wrote a tool, is in the main window CreateDialog child window, the child window for child mode, then start, found the child window not receive mouse events, mouse movements, mouse the left key right, etc., the parent window was also not receive mouse events, depressed
Don't know if that place did not set up correctly, or say, and masters, such as online,
The main window to create a child window,
Case WM_CREATE message handler://build window
M_hDrawWnd=CreateDialog (m_hInst, MAKEINTRESOURCE (IDD_DLG_DRAW), HWND, DialogDraw);
ShowWindow (m_hDrawWnd, SW_SHOW);
break;
.
CodePudding user response:
Has been solved!I feel clean,
The HWND CreateDialog (HINSTANCE hlnstance, LPCTSTR lpTemplate, HWND hWndParent, DLGPROC IpDialogFunc);
The last parameter not event handler?
Have to reset the SetWindowLong two for yao,
Change a problem, who can explain it, is a bug or meaning is different,