From 7ff567d584cd1772f740144f93a6684bb9d95c70 Mon Sep 17 00:00:00 2001 From: Rasmus Karlsson Date: Sat, 31 Aug 2019 17:44:41 +0200 Subject: [PATCH] rename "messageReceived" to "readConnectionMessageReceived" to match the "readConnected/writeConnected" and "writeConnectionMessageReceived" functions --- src/providers/irc/AbstractIrcServer.cpp | 11 ++++++----- src/providers/irc/AbstractIrcServer.hpp | 2 +- src/providers/twitch/TwitchServer.cpp | 2 +- src/providers/twitch/TwitchServer.hpp | 3 ++- 4 files changed, 10 insertions(+), 8 deletions(-) diff --git a/src/providers/irc/AbstractIrcServer.cpp b/src/providers/irc/AbstractIrcServer.cpp index e6703d9d7..3e9c0b6b3 100644 --- a/src/providers/irc/AbstractIrcServer.cpp +++ b/src/providers/irc/AbstractIrcServer.cpp @@ -30,9 +30,9 @@ AbstractIrcServer::AbstractIrcServer() this->readConnection_.reset(new IrcConnection); this->readConnection_->moveToThread(QCoreApplication::instance()->thread()); - QObject::connect(this->readConnection_.get(), - &Communi::IrcConnection::messageReceived, - [this](auto msg) { this->messageReceived(msg); }); + QObject::connect( + this->readConnection_.get(), &Communi::IrcConnection::messageReceived, + [this](auto msg) { this->readConnectionMessageReceived(msg); }); QObject::connect(this->readConnection_.get(), &Communi::IrcConnection::privateMessageReceived, [this](auto msg) { this->privateMessageReceived(msg); }); @@ -317,7 +317,7 @@ void AbstractIrcServer::addFakeMessage(const QString &data) } else { - this->messageReceived(fakeMessage); + this->readConnectionMessageReceived(fakeMessage); } } @@ -326,7 +326,8 @@ void AbstractIrcServer::privateMessageReceived( { } -void AbstractIrcServer::messageReceived(Communi::IrcMessage *message) +void AbstractIrcServer::readConnectionMessageReceived( + Communi::IrcMessage *message) { } diff --git a/src/providers/irc/AbstractIrcServer.hpp b/src/providers/irc/AbstractIrcServer.hpp index bd71a711a..98abc970c 100644 --- a/src/providers/irc/AbstractIrcServer.hpp +++ b/src/providers/irc/AbstractIrcServer.hpp @@ -49,7 +49,7 @@ protected: const QString &channelName) = 0; virtual void privateMessageReceived(Communi::IrcPrivateMessage *message); - virtual void messageReceived(Communi::IrcMessage *message); + virtual void readConnectionMessageReceived(Communi::IrcMessage *message); virtual void writeConnectionMessageReceived(Communi::IrcMessage *message); virtual void onReadConnected(IrcConnection *connection); diff --git a/src/providers/twitch/TwitchServer.cpp b/src/providers/twitch/TwitchServer.cpp index 19d5591f5..fa1b158ac 100644 --- a/src/providers/twitch/TwitchServer.cpp +++ b/src/providers/twitch/TwitchServer.cpp @@ -128,7 +128,7 @@ void TwitchServer::privateMessageReceived(Communi::IrcPrivateMessage *message) IrcMessageHandler::getInstance().handlePrivMessage(message, *this); } -void TwitchServer::messageReceived(Communi::IrcMessage *message) +void TwitchServer::readConnectionMessageReceived(Communi::IrcMessage *message) { if (message->type() == Communi::IrcMessage::Type::Private) { diff --git a/src/providers/twitch/TwitchServer.hpp b/src/providers/twitch/TwitchServer.hpp index 847fe4c86..e0adcf6ef 100644 --- a/src/providers/twitch/TwitchServer.hpp +++ b/src/providers/twitch/TwitchServer.hpp @@ -51,7 +51,8 @@ protected: virtual void privateMessageReceived( Communi::IrcPrivateMessage *message) override; - virtual void messageReceived(Communi::IrcMessage *message) override; + virtual void readConnectionMessageReceived( + Communi::IrcMessage *message) override; virtual void writeConnectionMessageReceived( Communi::IrcMessage *message) override;