예제 #1
0
		public override void Execute(object parameter)
		{
			var classBrowser = SD.GetService<IClassBrowser>();
			var modelFactory = SD.GetService<IModelFactory>();
			if ((classBrowser != null) && (modelFactory != null)) {
				OpenFromGacDialog gacDialog = new OpenFromGacDialog();
				if (gacDialog.ShowDialog() ?? false)
				{
					foreach (string assemblyFile in gacDialog.SelectedFileNames) {
						IAssemblyModel assemblyModel = SD.AssemblyParserService.GetAssemblyModelSafe(new ICSharpCode.Core.FileName(assemblyFile), true);
						if (assemblyModel != null)
							classBrowser.MainAssemblyList.Assemblies.Add(assemblyModel);
					}
				}
			}
		}
예제 #2
0
        public override void Execute(object parameter)
        {
            var classBrowser = SD.GetService <IClassBrowser>();
            var modelFactory = SD.GetService <IModelFactory>();

            if ((classBrowser != null) && (modelFactory != null))
            {
                OpenFromGacDialog gacDialog = new OpenFromGacDialog();
                if (gacDialog.ShowDialog() ?? false)
                {
                    foreach (string assemblyFile in gacDialog.SelectedFileNames)
                    {
                        IAssemblyModel assemblyModel = SD.AssemblyParserService.GetAssemblyModelSafe(new ICSharpCode.Core.FileName(assemblyFile), true);
                        if (assemblyModel != null)
                        {
                            classBrowser.MainAssemblyList.Assemblies.Add(assemblyModel);
                        }
                    }
                }
            }
        }