public void SetEnabled(Plugin plugin, bool enabled) { if ((enabled && disabled.Remove(plugin.Identifier)) || (!enabled && disabled.Add(plugin.Identifier))) { PluginChangedState?.Invoke(this, new PluginChangedStateEventArgs(plugin, enabled)); } }
private void Config_InternalPluginChangedState(object sender, PluginChangedStateEventArgs e) { PluginChangedState?.Invoke(this, e); Config.Save(configPath); }