public ClientStatusDisplay(ClientHandler client)
        {
            InitializeComponent();
            this._client = client;
            this.Client.Authenticated += new EventHandler(this.client_Authenticated);
            this.Client.Disconnected += new EventHandler(this.client_Disconnected);
            this.Client.MessageReceived += new EventHandler<MessageEventArgs>(this.client_MessageReceived);

            DisableControls();
            txtClientAddress.Text = this.Client.GetIPAddress();
        }
Пример #2
0
 private static void socketListener_ClientConnected(object sender, ClientEventArgs e)
 {
     try
     {
         var client = new ClientHandler(e.Connection);
         _clients.Add(client);
         SMLogger.LogThis("Client connected");
     }
     catch (Exception ex)
     {
         SMLogger.LogThis(ex.ToString());
     }
 }