X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fcore%2Fcoresession.cpp;h=11a95301b3f861eb4fc9912377ed37d59e5a7a88;hp=3bab9d9d034620e64e17af5590a44e1193b24873;hb=db00831bca59a012242d1ad5fac52a20c6cd2956;hpb=b8ce41ef6c0036d854f5bef0fb52e2a69dc5def2 diff --git a/src/core/coresession.cpp b/src/core/coresession.cpp index 3bab9d9d..11a95301 100644 --- a/src/core/coresession.cpp +++ b/src/core/coresession.cpp @@ -90,29 +90,25 @@ CoreSession::CoreSession(UserId uid, bool restoreState, bool strictIdentEnabled, connect(p, &SignalProxy::connected, this, &CoreSession::clientsConnected); connect(p, &SignalProxy::disconnected, this, &CoreSession::clientsDisconnected); - p->attachSlot(SIGNAL(sendInput(BufferInfo, QString)), this, SLOT(msgFromClient(BufferInfo, QString))); - p->attachSignal(this, SIGNAL(displayMsg(Message))); - p->attachSignal(this, SIGNAL(displayStatusMsg(QString, QString))); - - p->attachSignal(this, SIGNAL(identityCreated(const Identity&))); - p->attachSignal(this, SIGNAL(identityRemoved(IdentityId))); - p->attachSlot(SIGNAL(createIdentity(const Identity&, const QVariantMap&)), - this, - SLOT(createIdentity(const Identity&, const QVariantMap&))); - p->attachSlot(SIGNAL(removeIdentity(IdentityId)), this, SLOT(removeIdentity(IdentityId))); - - p->attachSignal(this, SIGNAL(networkCreated(NetworkId))); - p->attachSignal(this, SIGNAL(networkRemoved(NetworkId))); - p->attachSlot(SIGNAL(createNetwork(const NetworkInfo&, const QStringList&)), - this, - SLOT(createNetwork(const NetworkInfo&, const QStringList&))); - p->attachSlot(SIGNAL(removeNetwork(NetworkId)), this, SLOT(removeNetwork(NetworkId))); - - p->attachSlot(SIGNAL(changePassword(PeerPtr, QString, QString, QString)), this, SLOT(changePassword(PeerPtr, QString, QString, QString))); - p->attachSignal(this, SIGNAL(passwordChanged(PeerPtr, bool))); - - p->attachSlot(SIGNAL(kickClient(int)), this, SLOT(kickClient(int))); - p->attachSignal(this, SIGNAL(disconnectFromCore())); + p->attachSlot(SIGNAL(sendInput(BufferInfo,QString)), this, &CoreSession::msgFromClient); + p->attachSignal(this, &CoreSession::displayMsg); + p->attachSignal(this, &CoreSession::displayStatusMsg); + + p->attachSignal(this, &CoreSession::identityCreated); + p->attachSignal(this, &CoreSession::identityRemoved); + p->attachSlot(SIGNAL(createIdentity(Identity,QVariantMap)), this, selectOverload(&CoreSession::createIdentity)); + p->attachSlot(SIGNAL(removeIdentity(IdentityId)), this, &CoreSession::removeIdentity); + + p->attachSignal(this, &CoreSession::networkCreated); + p->attachSignal(this, &CoreSession::networkRemoved); + p->attachSlot(SIGNAL(createNetwork(NetworkInfo,QStringList)), this,&CoreSession::createNetwork); + p->attachSlot(SIGNAL(removeNetwork(NetworkId)), this, &CoreSession::removeNetwork); + + p->attachSlot(SIGNAL(changePassword(PeerPtr,QString,QString,QString)), this, &CoreSession::changePassword); + p->attachSignal(this, &CoreSession::passwordChanged); + + p->attachSlot(SIGNAL(kickClient(int)), this, &CoreSession::kickClient); + p->attachSignal(this, &CoreSession::disconnectFromCore); QVariantMap data; data["quasselVersion"] = Quassel::buildInfo().fancyVersionString; @@ -518,8 +514,8 @@ Protocol::SessionState CoreSession::sessionState() const void CoreSession::initScriptEngine() { - signalProxy()->attachSlot(SIGNAL(scriptRequest(QString)), this, SLOT(scriptRequest(QString))); - signalProxy()->attachSignal(this, SIGNAL(scriptResult(QString))); + signalProxy()->attachSlot(SIGNAL(scriptRequest(QString)), this, &CoreSession::scriptRequest); + signalProxy()->attachSignal(this, &CoreSession::scriptResult); // FIXME // QScriptValue storage_ = scriptEngine->newQObject(storage);