So, I have a plugin for the MFC program. I use the mouse event hook (from SetWindowsHookEx) to capture clicks. A host application can have any number of (possibly overlapping) child windows, but I only want to intercept clicks in a specific child window.
Is there a way to calculate in hook proc which of the child windows will handle the click? I suppose this is something like listing all the child windows looking at the Z-order, but I am very unfamiliar with the MFC / Win32 libraries, and I cannot find a good discussion on how to list all the children and figure out what the top one is.
source
share