void ICQClient::moveUser(ICQUser *u, ICQGroup *g) { if (u->Uin >= UIN_SPECIAL){ MoveUserEvent *e = new MoveUserEvent(u->Uin, g->Id); if (e->process(p, 0)) process_event(e); delete e; return; } p->moveUser(u, g); }
void ICQClient::moveUser(ICQUser *u, ICQGroup *g) { unsigned short id = contacts.getUserId(u); MoveUserEvent *e = new MoveUserEvent(u->Uin, g->Id()); if (u->Uin() >= UIN_SPECIAL){ if (e->process(this, 0)) process_event(e); delete e; return; } if (m_state != Logged) return; if (!u->GrpId()){ snac(ICQ_SNACxFAM_LISTS, ICQ_SNACxLISTS_CREATE_USER); writeBuffer.packUin(u->Uin); writeBuffer << 0x00000000L; sendPacket(); } snac(ICQ_SNACxFAM_LISTS, ICQ_SNACxLISTS_EDIT); sendPacket(); sendRoster(e, ICQ_SNACxLISTS_CREATE, u->Uin, g->Id(), id, 0, u->Alias.c_str(), u->WaitAuth()); }