static void ServerRehash(object sender, RehashEventArgs e) { var settings = new IRCSettings(); settings.SetDaemon(e.IrcDaemon); settings.LoadSettings(); }
public void Run() { var settings = new IRCSettings(); var ircDaemon = new IrcDaemon(settings.GetIrcMode()); settings.SetDaemon(ircDaemon); settings.LoadSettings(); if (blocking) { ircDaemon.Start(); } else { ircDaemon.ServerRehash += ServerRehash; var serverThread = new Thread(ircDaemon.Start) { IsBackground = false, Name = "serverThread-1" }; serverThread.Start(); } }