public ChatWindow GetChatWindow(Contact contact) { var chatWindow = WindowsFactory.GetInstance() .GetChatWindow(contact, _senderService); return chatWindow; }
private void addBtn_Click(object sender, EventArgs e) { var newContact = new Contact(name.Text, ipDirection.Text); _contactManager.AddContact(newContact); }
public void AddContact(Contact contact) { _contacts.Items.Add(contact); }
public ChatWindow(Contact contact, SenderService senderService) { InitializeComponent(); _contact = contact; _senderService = senderService; }
public ChatWindow GetChatWindow(Contact contact, SenderService senderService) { return new ChatWindow(contact, senderService); }