void QuetzalAccount::addChatUnit(ChatUnit *unit) { m_units.insert(unit->id(), unit); qDebug() << m_units.keys(); if (Conference *conference = qobject_cast<Conference*>(unit)) conferenceCreated(conference); }
IrcChannel *IrcAccount::getChannel(const QString &name, bool create) { QString nameLower = name.toLower(); IrcChannel *channel = d->channels.value(nameLower); if (create && !channel) { channel = new IrcChannel(this, name); d->channels.insert(nameLower, channel); emit conferenceCreated(channel); } return channel; }