X-Git-Url: https://git.quassel-irc.org/?a=blobdiff_plain;ds=sidebyside;f=src%2Fcore%2Fkeyevent.h;h=65db084a9bc6a6a6a318c4711b07b9b379b19790;hb=fcacaaf16551524c7ebb6114254d005274cc3d63;hp=9c24fbb13ad1fc41a475ba2b2065c602e52e6703;hpb=8b07343ab53d37b5340a56bde2d71ff2a3afb14a;p=quassel.git diff --git a/src/core/keyevent.h b/src/core/keyevent.h index 9c24fbb1..65db084a 100644 --- a/src/core/keyevent.h +++ b/src/core/keyevent.h @@ -21,6 +21,8 @@ #ifndef KEYEVENT_H #define KEYEVENT_H +#include + #include "ircevent.h" class KeyEvent : public IrcEvent @@ -31,13 +33,13 @@ public: Finish }; - explicit KeyEvent(EventManager::EventType type, Network *network, const QString &prefix, const QString &target, - ExchangeType exchangeType, const QByteArray &key, + explicit KeyEvent(EventManager::EventType type, Network *network, const QString &prefix, QString target, + ExchangeType exchangeType, QByteArray key, const QDateTime ×tamp = QDateTime()) : IrcEvent(type, network, prefix), _exchangeType(exchangeType), - _target(target), - _key(key) + _target(std::move(target)), + _key(std::move(key)) { setTimestamp(timestamp); } @@ -56,10 +58,10 @@ public: protected: explicit KeyEvent(EventManager::EventType type, QVariantMap &map, Network *network); - void toVariantMap(QVariantMap &map) const; + void toVariantMap(QVariantMap &map) const override; - virtual inline QString className() const { return "KeyEvent"; } - virtual inline void debugInfo(QDebug &dbg) const + inline QString className() const override { return "KeyEvent"; } + inline void debugInfo(QDebug &dbg) const override { NetworkEvent::debugInfo(dbg); dbg << ", prefix = " << qPrintable(prefix())