Beispiel #1
0
		List<Info> GetInfos() {
			var infos = new List<Info>();

			infos.Add(new Info(GetType().Assembly, CreateDnSpyInfo()));

			var toExtension = new Dictionary<Assembly, IExtension>();
			foreach (var extension in extensionService.Extensions)
				toExtension[extension.GetType().Assembly] = extension;

			// Show the extensions in random order
			var random = new Random();
			foreach (var x in extensionService.LoadedExtensions.OrderBy(a => random.Next())) {
				ExtensionInfo extensionInfo;
				IExtension extension;
				if (toExtension.TryGetValue(x.Assembly, out extension))
					extensionInfo = extension.ExtensionInfo;
				else
					extensionInfo = new ExtensionInfo();

				infos.Add(new Info(x.Assembly, extensionInfo));
			}

			return infos;
		}
Beispiel #2
0
			public Info(Assembly asm, ExtensionInfo info) {
				Assembly = asm;
				ExtensionInfo = info;
			}