Ove Kaaven ovehk@ping.uio.no writes:
This is incorrect, but I guess my code was also. For example, dialog boxes are popup windows parented by their owner. They are not clipped to their parent, but dialogs should probably also be managed. Hmm...
You seem to confuse parent and owner. win->parent is always the real parent in the window hierarchy, no matter whether the window is owned or not. It will be the desktop for all top-level windows, including menus, popup dialogs, etc.
Of course to make things simple the 'parent' parameter of CreateWindow sometimes means parent and sometimes owner. But in the window data structure they are two separate fields. In any case I don't think we can use the owner to distinguish managed/non-managed either.