Z-order of children
-
Anyone know how to reset the z-order of a window's children to be a specified z-order? Actually, I only need to be able to specify which child to be on top. I am hoping to control which child window gets the mouse click this way. So far setting focus does not work to determine who gtets the mouse click. SetActiveWindow does not affect the z-order, and I think that there is nothing to counter-act it but I will attempt to ensure that that is not a problem.
-
Anyone know how to reset the z-order of a window's children to be a specified z-order? Actually, I only need to be able to specify which child to be on top. I am hoping to control which child window gets the mouse click this way. So far setting focus does not work to determine who gtets the mouse click. SetActiveWindow does not affect the z-order, and I think that there is nothing to counter-act it but I will attempt to ensure that that is not a problem.
To set the Z-Order: SetWindowPos(hWnd, HWND_TOP, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE)
-
To set the Z-Order: SetWindowPos(hWnd, HWND_TOP, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE)
Thank you. I think it is working. Since I am using MFC, I converted your sample to: m_pEditWindow->SetWindowPos(&wndTop, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE); There are still some problems with my program but it is likely that they are separate problems. I think that the z-order part is probably solved.