GetParent
Function can return an owner window instead of a parent window.
Window GetParent( )
If the window is a child window, the return value is the parent window.
If the window is a top-level window, the return value is the owner window.
If the window is a top-level unowned window or if the function fails, the return value is NULL.
origin.h