--- trunk/RomCheater.PluginFramework/Events/ProcessChangedEventArgs.cs 2013/06/17 08:33:06 683 +++ trunk/RomCheater.PluginFramework/Events/ProcessChangedEventArgs.cs 2013/06/17 08:52:54 684 @@ -2,6 +2,7 @@ using System.Collections.Generic; using System.Linq; using System.Text; +using RomCheater.PluginFramework.Interfaces; namespace RomCheater.PluginFramework.Events { @@ -24,4 +25,23 @@ namespace RomCheater.PluginFramework.Eve public int ProcessID { get; private set; } #endregion } + + public interface IAcceptsChangedConfig + { + event BaseEventHandler<ConfigChangedEventArgs> OnSelectedConfigChanged; + } + public interface IConfigChangedEventArgs + { + IConfigPlugin ConfigPlugin { get; } + } + public class ConfigChangedEventArgs : BaseEventArgs, IConfigChangedEventArgs + { + public ConfigChangedEventArgs() : this(-1) { } + public ConfigChangedEventArgs(object sender) : this(sender, null) { } + public ConfigChangedEventArgs(IConfigPlugin config) : base() { this.ConfigPlugin = config; } + public ConfigChangedEventArgs(object sender, IConfigPlugin config) : base(sender) { this.ConfigPlugin = config; } + #region IConfigChangedEventArgs members + public IConfigPlugin ConfigPlugin { get; private set; } + #endregion + } } |