public void RemoveSignalHandler(SignalEntry entry) { SignalEntry.HandleSignalMessageDelegate handler; if (this.signals.TryGetValue(entry.key, out handler)) { handler -= entry.signalHandler; this.signals[entry.key] = handler; // Seriously ? Sigh... } }
public void AddSignalHandler(SignalEntry entry) { SignalEntry.HandleSignalMessageDelegate handler; if (this.signals.TryGetValue(entry.key, out handler)) { handler += entry.signalHandler; this.signals[entry.key] = handler; // Seriously ? Sigh... } else { this.signals[entry.key] = entry.signalHandler; } }