0
votes

I use PopupWindowAction class for creation of modal dialog windows (customized and predefined) in my Prism 6 WPF modular application with Unity. (I have Windows 10 on my computer and use MS VS 2015 Professional as development environment.) This is for customized modal dialog:

<i:Interaction.Triggers>
    <prism:InteractionRequestTrigger SourceObject="{Binding LoginConfirmationRequest, Mode=OneWay}">
         <prism:PopupWindowAction IsModal="True" CenterOverAssociatedObject="True">
              <prism:PopupWindowAction.WindowContent>
                    <views:LoginView />
              </prism:PopupWindowAction.WindowContent>
            </prism:PopupWindowAction>
    </prism:InteractionRequestTrigger>
</i:Interaction.Triggers>

Where LoginView is Prism UserControl(WPF) used for representation of login dialog content. XAML below is for predefined dialog:

<i:Interaction.Triggers>
    <prism:InteractionRequestTrigger SourceObject="{Binding NotificationRequest, Mode=OneWay}">
        <prism:PopupWindowAction IsModal="True" CenterOverAssociatedObject="True"/>
    </prism:InteractionRequestTrigger>
</i:Interaction.Triggers>

But there is a problem: When dialog (indifferently customized or predefined but with IsModal="True" property of PopupWindowAction) is displayed atop Shell and I begin (in order to verify that dialog is modal) perform frequent clicks by left mouse button on Shell area around the dialog then the dialog is going to background and Shell is displaying atop of the dialog. I just notice it not only in my application but also in InteractivityQuickstart example application. Why is this happening? How to set strong modality for customized and predefined dialogs? Please help me.

1

1 Answers

0
votes

This has been fixed in the latest Pre-release, and the fix will be made available with the next RTM release of Prism 6.2

https://github.com/PrismLibrary/Prism/wiki/Release-Notes--Jan-10,-2016#prism-for-wpf-611-pre2

The issue was that the window owner was never being set.