modernize: Replace most remaining old-style connects by PMF ones
[quassel.git] / src / common / ircchannel.cpp
index dd47f85..37318d9 100644 (file)
@@ -44,11 +44,6 @@ IrcChannel::IrcChannel(const QString &channelname, Network *network)
 }
 
 
-IrcChannel::~IrcChannel()
-{
-}
-
-
 // ====================
 //  PUBLIC:
 // ====================
@@ -196,7 +191,7 @@ void IrcChannel::joinIrcUsers(const QList<IrcUser *> &users, const QStringList &
 
         _userModes[ircuser] = sortedModes[i];
         ircuser->joinChannel(this, true);
-        connect(ircuser, SIGNAL(nickSet(QString)), this, SLOT(ircUserNickSet(QString)));
+        connect(ircuser, &IrcUser::nickSet, this, selectOverload<QString>(&IrcChannel::ircUserNickSet));
 
         // connect(ircuser, SIGNAL(destroyed()), this, SLOT(ircUserDestroyed()));
         // If you wonder why there is no counterpart to ircUserJoined:
@@ -429,7 +424,7 @@ void IrcChannel::initSetChanModes(const QVariantMap &channelModes)
 
 void IrcChannel::ircUserDestroyed()
 {
-    IrcUser *ircUser = static_cast<IrcUser *>(sender());
+    auto *ircUser = static_cast<IrcUser *>(sender());
     Q_ASSERT(ircUser);
     _userModes.remove(ircUser);
     // no further propagation.
@@ -439,7 +434,7 @@ void IrcChannel::ircUserDestroyed()
 
 void IrcChannel::ircUserNickSet(QString nick)
 {
-    IrcUser *ircUser = qobject_cast<IrcUser *>(sender());
+    auto *ircUser = qobject_cast<IrcUser *>(sender());
     Q_ASSERT(ircUser);
     emit ircUserNickSet(ircUser, nick);
 }