Ejemplo n.º 1
0
 public static IEnumerable<IResult> AddGacReferences()
 {
     var windowSettings = new Dictionary<string, object> { { "SizeToContent", SizeToContent.Manual }, { "Width", 500.0 }, { "Height", 500.0 } };
     var dialog = new AssemblyGacViewModel();
     yield return Show.Dialog(dialog, windowSettings);
     var selectedAssemblies = dialog.SelectedAssemblies.Select(item => item.AssemblyName).ToArray();
     if (selectedAssemblies.Length > 0)
     {
         yield return new AddReferencesResult(selectedAssemblies);
     }
 }
        public IEnumerable <IResult> AddReferenceFromGac()
        {
            var windowSettings = new Dictionary <string, object> {
                { "SizeToContent", SizeToContent.Manual }, { "Width", 500.0 }, { "Height", 500.0 }
            };
            var dialog = new AssemblyGacViewModel();

            yield return(Show.Dialog(dialog, windowSettings));

            var selectedAssemblies = dialog.SelectedAssemblies.Select(item => item.AssemblyName).ToArray();

            if (selectedAssemblies.Length <= dialog.MaxSelectedAssemblyCount)
            {
                yield return(new AddReferencesResult(assemblyReferences, dialog.SelectedAssemblies.Select(item => item.AssemblyName)));
            }
        }
Ejemplo n.º 3
0
 public IEnumerable<IResult> AddReferenceFromGac()
 {
     var windowSettings = new Dictionary<string, object> { { "SizeToContent", SizeToContent.Manual }, { "Width", 500.0 }, { "Height", 500.0 } };
     var dialog = new AssemblyGacViewModel();
     yield return Show.Dialog(dialog, windowSettings);
     var selectedAssemblies = dialog.SelectedAssemblies.Select(item => item.AssemblyName).ToArray();
     if (selectedAssemblies.Length <= dialog.MaxSelectedAssemblyCount)
         yield return new AddReferencesResult(CShell.Shell.Workspace.Assemblies, dialog.SelectedAssemblies.Select(item => item.AssemblyName));
 }