FlowChartModuleModule.cs 662 B

123456789101112131415161718192021222324
  1. using FlowChartModule.Views;
  2. using FlowChartModule.绘制模块;
  3. using Prism.Ioc;
  4. using Prism.Modularity;
  5. using Prism.Regions;
  6. namespace FlowChartModule
  7. {
  8. public class FlowChartModuleModule : IModule
  9. {
  10. public void OnInitialized(IContainerProvider containerProvider)
  11. {
  12. var regionManager = containerProvider.Resolve<RegionManager>();
  13. regionManager.RegisterViewWithRegion("ContentRegion", typeof(ModuleView));
  14. }
  15. public void RegisterTypes(IContainerRegistry containerRegistry)
  16. {
  17. containerRegistry.RegisterSingleton<DrawModule>();
  18. }
  19. }
  20. }