private void OnRosterItem(object sender, agsXMPP.protocol.iq.roster.RosterItem item) { if (InvokeRequired) { BeginInvoke(new XmppClientConnection.RosterHandler(OnRosterItem), new object[] { this, item }); return; } if (item.Subscription == SubscriptionType.both) { for (int i = 0; i < listBox1.Items.Count; i++) { if (item.Jid.ToString() == listBox1.Items[i].ToString()) { listBox1.Items.Remove(item.Jid); } } listBox1.Items.Add(item.Jid.ToString()); } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)