X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fclient%2Fclient.cpp;h=bfce15d195e2298c3a72a0134ec2186c4f70986e;hp=899991f7c17696c627c572eeebcf87558eb21cec;hb=7795adca52f35204f8c354da6fcc5d8e8ee35531;hpb=0208d04a0b8c25f3c77727a68eef94ce2d608690 diff --git a/src/client/client.cpp b/src/client/client.cpp index 899991f7..bfce15d1 100644 --- a/src/client/client.cpp +++ b/src/client/client.cpp @@ -139,6 +139,7 @@ Client::Client(QObject *parent) } Client::~Client() { + } void Client::init() { @@ -281,7 +282,7 @@ void Client::coreSocketDisconnected() { net->deleteLater(); } Q_ASSERT(_networkInfo.isEmpty()); - + coreConnectionInfo.clear(); sessionData.clear(); layoutQueue.clear(); @@ -448,6 +449,7 @@ void Client::networkConnected(uint netid) { connect(netinfo, SIGNAL(ircUserInitDone()), this, SLOT(updateCoreConnectionProgress())); connect(netinfo, SIGNAL(ircChannelInitDone()), this, SLOT(updateCoreConnectionProgress())); } + connect(netinfo, SIGNAL(ircChannelAdded(QString)), this, SLOT(ircChannelAdded(QString))); connect(netinfo, SIGNAL(destroyed()), this, SLOT(networkInfoDestroyed())); _networkInfo[netid] = netinfo; } @@ -460,7 +462,7 @@ void Client::networkDisconnected(uint networkid) { //buffer->displayMsg(Message(bufferid, Message::Server, tr("Server disconnected."))); FIXME buffer->setActive(false); } - + Q_ASSERT(networkInfo(networkid)); if(!networkInfo(networkid)->initialized()) { qDebug() << "Network" << networkid << "disconnected while not yet initialized!"; @@ -468,6 +470,15 @@ void Client::networkDisconnected(uint networkid) { } } +void Client::ircChannelAdded(QString chanName) { + NetworkInfo *netInfo = qobject_cast(sender()); + Q_ASSERT(netInfo); + Buffer *buf = buffer(bufferInfo(netInfo->networkName(), chanName)); + Q_ASSERT(buf); + buf->setIrcChannel(netInfo->ircChannel(chanName)); + +} + void Client::updateBufferInfo(BufferInfo id) { buffer(id)->updateBufferInfo(id); }