I'm using Caliburn Micro and Ninject together in a WPF app. I'm using Ninject.Extensions.Interception to intercept and log calls to my ViewModels, however this is preventing Caliburn to locate the view for ViewModels because Caliburn is being handed the intercepted viewModel (proxy) which is of a different namespace and name.
For instance, instead of getting:
MyApp.ViewModels.OrdersViewModel
it is getting:
Castle.Proxies.IOrdersProxy
To complicate things even further, ViewModels and Views are located in different assemblies, so namespace cannot be assumed.
Since I need to interrogate the proxy at runtime I need a way to hook into the View resolution programatically rather than by adding string mappings. I do not see any way to do this - is it possible with Calliburn Micro?
OK I got it. Instead of fighting the mappings, I am unwrapping the proxy in the WindowManager instead:
Also in case you are wondering what IWindowManagerEx is: