X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fcommon%2Fmessageevent.h;h=7e6df2667d80fc0d6ce3593cd51db5194a69c76e;hp=4f476b42e6ef813a4d7472198d0c378607ecd57f;hb=6eefdfc697067d184a589fc8a231b16316c09106;hpb=694f9bfbf7f1af19108461c7e00d133e55082bce diff --git a/src/common/messageevent.h b/src/common/messageevent.h index 4f476b42..7e6df266 100644 --- a/src/common/messageevent.h +++ b/src/common/messageevent.h @@ -1,5 +1,5 @@ /*************************************************************************** - * Copyright (C) 2005-2012 by the Quassel Project * + * Copyright (C) 2005-2018 by the Quassel Project * * devel@quassel-irc.org * * * * This program is free software; you can redistribute it and/or modify * @@ -15,11 +15,12 @@ * You should have received a copy of the GNU General Public License * * along with this program; if not, write to the * * Free Software Foundation, Inc., * - * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * ***************************************************************************/ -#ifndef MESSAGEEVENT_H -#define MESSAGEEVENT_H +#pragma once + +#include "common-export.h" #include "message.h" #include "networkevent.h" @@ -27,14 +28,14 @@ // this corresponds to CoreSession::RawMessage for now and should contain the information we need to convert events // into messages for the legacy code to work with -class MessageEvent : public NetworkEvent +class COMMON_EXPORT MessageEvent : public NetworkEvent { public: explicit MessageEvent(Message::Type msgType, Network *network, - const QString &msg, + QString msg, const QString &sender = QString(), - const QString &target = QString(), + QString target = QString(), Message::Flags msgFlags = Message::None, const QDateTime ×tamp = QDateTime() ); @@ -57,10 +58,10 @@ public: protected: explicit MessageEvent(EventManager::EventType type, QVariantMap &map, Network *network); - void toVariantMap(QVariantMap &map) const; + void toVariantMap(QVariantMap &map) const override; - virtual inline QString className() const { return "MessageEvent"; } - virtual inline void debugInfo(QDebug &dbg) const + inline QString className() const override { return "MessageEvent"; } + inline void debugInfo(QDebug &dbg) const override { NetworkEvent::debugInfo(dbg); dbg.nospace() << ", sender = " << qPrintable(sender()) @@ -80,6 +81,3 @@ private: QString _text, _sender, _target; Message::Flags _msgFlags; }; - - -#endif