X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fcore%2Fcoresession.h;h=3bc7cd0ac4c07f2e8bc1ec8d2005d54f1c56eacf;hp=a164ffe1575256f96ca327246371b5c572fa2b8a;hb=16f22647e6890d3eb8c3e94f7a0700e12fa29e44;hpb=5e6f3661d30bc760f912dfe0627e5c62c6f2c144 diff --git a/src/core/coresession.h b/src/core/coresession.h index a164ffe1..3bc7cd0a 100644 --- a/src/core/coresession.h +++ b/src/core/coresession.h @@ -1,5 +1,5 @@ /*************************************************************************** - * Copyright (C) 2005-2015 by the Quassel Project * + * Copyright (C) 2005-2016 by the Quassel Project * * devel@quassel-irc.org * * * * This program is free software; you can redistribute it and/or modify * @@ -31,10 +31,12 @@ #include "protocol.h" #include "message.h" #include "storage.h" +#include "corehighlightrulemanager.h" class CoreBacklogManager; class CoreBufferSyncer; class CoreBufferViewManager; +class CoreDccConfig; class CoreIdentity; class CoreIrcListHelper; class CoreNetwork; @@ -86,7 +88,9 @@ public: inline CoreIrcListHelper *ircListHelper() const { return _ircListHelper; } inline CoreIgnoreListManager *ignoreListManager() { return &_ignoreListManager; } + inline HighlightRuleManager *highlightRuleManager() { return &_highlightRuleManager; } inline CoreTransferManager *transferManager() const { return _transferManager; } + inline CoreDccConfig *dccConfig() const { return _dccConfig; } // void attachNetworkConnection(NetworkConnection *conn); @@ -129,10 +133,17 @@ public slots: void changePassword(PeerPtr peer, const QString &userName, const QString &oldPassword, const QString &newPassword); + void kickClient(int peerId); + QHash persistentChannels(NetworkId) const; - //! Marks us away (or unaway) on all networks - void globalAway(const QString &msg = QString()); + /** + * Marks us away (or unaway) on all networks + * + * @param[in] msg Away message, or blank to set unaway + * @param[in] skipFormatting If true, skip timestamp formatting codes (e.g. if already done) + */ + void globalAway(const QString &msg = QString(), const bool skipFormatting = false); signals: void initialized(); @@ -162,6 +173,8 @@ signals: void passwordChanged(PeerPtr peer, bool success); + void disconnectFromCore(); + protected: virtual void customEvent(QEvent *event); @@ -203,6 +216,7 @@ private: CoreBufferSyncer *_bufferSyncer; CoreBacklogManager *_backlogManager; CoreBufferViewManager *_bufferViewManager; + CoreDccConfig *_dccConfig; CoreIrcListHelper *_ircListHelper; CoreNetworkConfig *_networkConfig; CoreCoreInfo _coreInfo; @@ -216,9 +230,17 @@ private: QScriptEngine *scriptEngine; + /** + * This method obtains the prefixes of the message's sender within a channel, by looking up their channelmodes, and + * processing them to prefixes based on the network's settings. + * @param sender The hostmask of the sender + * @param bufferInfo The BufferInfo object of the buffer + */ + QString senderPrefixes(const QString &sender, const BufferInfo &bufferInfo) const; QList _messageQueue; bool _processMessages; CoreIgnoreListManager _ignoreListManager; + CoreHighlightRuleManager _highlightRuleManager; };