From 43b8c6b54b001c62e1f87ceeff7d8f8c76fdb276 Mon Sep 17 00:00:00 2001 From: Latif Khalifa Date: Thu, 5 Dec 2013 00:16:58 +0100 Subject: [PATCH] Allow loading more than one plugin per assembly --- Programs/GridProxyGUI/PluginsScroller.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Programs/GridProxyGUI/PluginsScroller.cs b/Programs/GridProxyGUI/PluginsScroller.cs index 00551c3d..5ab31d79 100755 --- a/Programs/GridProxyGUI/PluginsScroller.cs +++ b/Programs/GridProxyGUI/PluginsScroller.cs @@ -123,6 +123,7 @@ namespace GridProxyGUI try { + bool started = false; Assembly assembly = Assembly.LoadFile(System.IO.Path.GetFullPath(path)); foreach (Type t in assembly.GetTypes()) { @@ -131,9 +132,11 @@ namespace GridProxyGUI ConstructorInfo info = t.GetConstructor(new Type[] { typeof(ProxyFrame) }); ProxyPlugin plugin = (ProxyPlugin)info.Invoke(new object[] { proxy }); plugin.Init(); - return true; + started = true; } } + + return started; } catch (Exception e) {