Quantcast
Channel: Windows Presentation Foundation (WPF) forum
Viewing all articles
Browse latest Browse all 18858

HWndHost BuildWindowCore and threads

$
0
0

In the docs for HWndHost.BuildWindowCore http://msdn.microsoft.com/en-us/library/system.windows.interop.hwndhost.buildwindowcore%28v=vs.110%29.aspx, which is the method you override to create your child Win32 window, it states

The window that you return must be a child of the window specified by hwndParent.

My question is why? I know I can create a child Win32 window on a separate thread if I control the parent Win32 so why the restriction imposed by WPF. I suspect this might be something to do with message loops given WPF seem to interfere with my ability to just add my own message processing loop and does stuff for me via HwndHost.WndProc.

Assuming there is some reason for this is in the HWndHost world is there some other way for me to create a child Win32 window of the WPF Win2 window that I really do control. So I can create it on a separate thread and do all my own message processing?


Viewing all articles
Browse latest Browse all 18858

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>