Hello,I am using a XamDockManager and a XamDialogWindow in my MVVM application and I have an error in view. - When the XamDockManager Splitspane is docked the Xamdialog window appears normaly and will be the top most window, but when the XamDockManager Splitspane is floating, and I want to open the XamDialogWindow, this window appear behind the floating window, or when I click on the window it also remains behind the split pane. What I want to achieve is that the XamDialogWindow is shown in the front of the split pane as the top most window in the application. What solution could be applied for these error, because my application is working with XamDialogWindows and I need this to work well with the XamDockManager I am using. To present the problem I have attached a sample, so you can see the behavior described above .Thanks,DVSE Gmbh
XamDialogWindow does not show a top level Window. It shows an element within the Window for which you have shown it. XamDockManager works like VS where the floating windows are separate top level windows. So it will not be possible to have the xamDialogWindow shown for the main window be above the floating panes.
Are there any suggested workarounds? I'm having the same issue. I need to use the DockManager, but I also need to move all floating panes to the background when I pop open a modal xamDialogWindow. Any help would be greatly appreciated. Thanks.
The xamDialogWindow isn't really meant to be used to show application modal windows - just a dialog that is "modal" to that window which is why it is hosted within that window's elements. You would either need to show a true modal WPF window or hide the floating panes. You might be able to use the 11.1 feature of making the floating windows unowned which would mean they could go behind the main window but there would be nothing to prevent the end user from bringing one of them to the foreground since as I mentioned the xamDialogWindow is only really modal to that window.
I tried the approach where I hosted the modal window within the ContentPane window, however the modal window still pops up behind the ContentPane. The XamDialogWindow does not seem to be modal to ContentPane. See example below:
ConfigModal configWindow = new ConfigModal(); // ConfigModal inherits from XamDialogWindowconfigWIndow.IsModal = true; this.LayoutRoot.Children.Add(configWindow) // this. refers to the current ContentPane
I don't see how that can be. If this.LayoutRoot is returning an element within the ContentPane then the xamDialogWindow would be within that element. I tested this out and it is within the ContentPane.
Any progress on this? I need a modal dialog to be shown, and my main window has a dock manager
Thanks
The xamDialogWindow does not display a top-level/standalone window. It is meant to display something that is modal to a particular area of a window - e.g. you have some control that you want to block input/interaction with but without suppressing interaction with some area of the window or application. If you need an application level modal window or want something that is a separate topmost window then you would just use a WPF Window and show it using its ShowDialog method.