Ejemplo n.º 1
0
        private void Chat_FormClosed(object sender, FormClosedEventArgs e)
        {
            var formchat = ClientManager.IsShow(_usernameReference);

            ClientManager.listFormChat.Remove(formchat);
            if (_icon != null)
            {
                _icon.Close();
            }
        }
Ejemplo n.º 2
0
 public void Friend_DoubleClick(object sender, EventArgs e)
 {
     {
         //khi double click vào tab show lient thì gọi form chat với client đó
         if (ClientManager.IsShow(_userFriend) == null)
         {
             Chat form2 = new Chat(client, _userFriend);
             form2.Text = _userFriend;
             ClientManager.listFormChat.Add(form2);
             Command cmd = new Command(CommandType_.LoadMessage, _userFriend, 0);
             client.SendCommand(cmd);
             form2.Show();
         }
     }
 }