Пример #1
0
        private void UserControlLoaded(object sender, System.Windows.RoutedEventArgs e)
        {
            var catalog = new DirectoryCatalog(Properties.Resources.PluginDirectory);
            var container = new CompositionContainer(catalog);
            _plugin = container.GetExportedValue<IPatientSelectPlugin>();

            HostContainer.Children.Add(_plugin.GetUserControl());

            var vm = ViewHelper.GetViewModel<SelectPatientViewModel>(this);
            vm.Model = _plugin.Model;
        }
Пример #2
0
        private void UserControlLoaded(object sender, System.Windows.RoutedEventArgs e)
        {
            var catalog   = new DirectoryCatalog(Properties.Resources.PluginDirectory);
            var container = new CompositionContainer(catalog);

            _plugin = container.GetExportedValue <IPatientSelectPlugin>();

            HostContainer.Children.Add(_plugin.GetUserControl());

            var vm = ViewHelper.GetViewModel <SelectPatientViewModel>(this);

            vm.Model = _plugin.Model;
        }