X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fqtui%2Fchatmonitorfilter.h;h=d7f4c4bda09930e7d640b3b8f4841e93f93f178c;hp=782797fb7c098c89c9f39b2a511a8ab6d282d782;hb=f824db0e31b54969e0b7fa0b5405b1e9173d482c;hpb=496d77836f54719491f2a117dbd2fb3e56def0b2 diff --git a/src/qtui/chatmonitorfilter.h b/src/qtui/chatmonitorfilter.h index 782797fb..d7f4c4bd 100644 --- a/src/qtui/chatmonitorfilter.h +++ b/src/qtui/chatmonitorfilter.h @@ -1,5 +1,5 @@ /*************************************************************************** -* Copyright (C) 2005-08 by the Quassel Project * +* Copyright (C) 2005-09 by the Quassel Project * * devel@quassel-irc.org * * * * This program is free software; you can redistribute it and/or modify * @@ -28,16 +28,42 @@ class ChatMonitorFilter : public MessageFilter { Q_OBJECT - public: - ChatMonitorFilter(MessageModel *model, QObject *parent = 0); +public: + enum SenderFields { + NoField = 0x00, + NetworkField = 0x01, + BufferField = 0x02, + SenderField = 0x04, + AllFields = 0xff + }; - virtual bool filterAcceptsRow(int sourceRow, const QModelIndex &sourceParent) const; - virtual QString idString() const; + ChatMonitorFilter(MessageModel *model, QObject *parent = 0); - virtual QVariant data(const QModelIndex &index, int role) const; + virtual bool filterAcceptsRow(int sourceRow, const QModelIndex &sourceParent) const; + virtual QString idString() const { return "ChatMonitor"; } + virtual QVariant data(const QModelIndex &index, int role) const; - private: - QDateTime _initTime; + int showFields() const { return _showFields; } + bool showOwnMessages() const { return _showOwnMessages; } + +public slots: + void addShowField(int field); + void removeShowField(int field); + void setShowOwnMessages(bool show); + +private slots: + void showFieldsSettingChanged(const QVariant &newValue); + void showOwnMessagesSettingChanged(const QVariant &newValue); + void showHighlightsSettingChanged(const QVariant &newValue); + void operationModeSettingChanged(const QVariant &newValue); + void buffersSettingChanged(const QVariant &newValue); + +private: + int _showFields; + bool _showOwnMessages; + QList _bufferIds; + bool _showHighlights; + int _operationMode; }; #endif