开发者

Need to control "Z Order" of windows within WPF Application

I have an application that, due to OpenGL airspace issues, has开发者_如何学编程 to host several controls in separate, exclusive windows. This is working quite well, but I am setting all of the windows to TopMost = true, which means that they do stay showing even when they lose focus, but they also overlay other applications. Also, it kind of binds me to using only one window at a time for this. Activate() doesn't work either.


I found that setting the windows' owners to the main app window allowed them to always float on top.

Inside the control that mediates the content and measurement of the child window:

InnerWindow.Owner = Window.GetWindow(this);

this being the windowHostControl hosting this window.


I use to combine Activate() and Focus() methods to show a hidden Window. Can you try using Focus() and let us know if this is working ?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜