Quantcast
Channel: patterns & practices: Prism
Viewing all articles
Browse latest Browse all 1878

New Post: In what order does Prism navigation instantiate/navigate nested regions/views/VMs?

$
0
0
My application doesn't use modules or MEF, so I don't think the proposed solution is relevant. Mine is a self-contained application with all views/VMs "living" in the main WPF project. I do still have an application "bootstrapper" where I register everything with the IoC container (including the views/VMs), and in its InitializeShell() method is where I use regionManager.RegisterViewWithRegion() to register the "child" views with the corresponding regions in the "parent" view.

All of the views in question are singletons, so I guess another option could be to force them to instantiate in (say) InitializeShell(), ensuring that they've subscribed to the event in their constructors? Still not particularly elegant though.

Thanks again

Viewing all articles
Browse latest Browse all 1878

Trending Articles



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