public static IEnumerable <LoadedTabPlugin> LoadTabPlugins(ControllerContext controllerContext) { var plugins = GetTabPlugins(controllerContext).ToList(); var loadedPlugins = new List <LoadedTabPlugin>(); foreach (var plugin in plugins) { var context = new TabLoadContext(controllerContext); plugin.OnLoad(context); loadedPlugins.Add(new LoadedTabPlugin(plugin, context)); } return(loadedPlugins); }
public static IEnumerable<LoadedTabPlugin> LoadTabPlugins(ControllerContext controllerContext) { var plugins = GetTabPlugins(controllerContext).ToList(); var loadedPlugins = new List<LoadedTabPlugin>(); foreach (var plugin in plugins) { var context = new TabLoadContext(controllerContext); plugin.OnLoad(context); loadedPlugins.Add(new LoadedTabPlugin(plugin, context)); } return loadedPlugins; }
public LoadedTabPlugin(ITabPlugin tabPlugin, TabLoadContext loadContext) { TabPlugin = tabPlugin; Context = loadContext; }
public abstract void OnLoad(TabLoadContext context);