X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fqtui%2Fchatview.h;h=998d9fc8162f00cc4ff753b5342e1f66cb48327f;hp=4a46d30c959de95401160dd91e2e7e6e7b49e6e9;hb=6e50e532fa24b8e36237eb7ae9c5c9b21058519f;hpb=8699dd758516d0ded076811e8ea656adc95e69d0 diff --git a/src/qtui/chatview.h b/src/qtui/chatview.h index 4a46d30c..998d9fc8 100644 --- a/src/qtui/chatview.h +++ b/src/qtui/chatview.h @@ -18,41 +18,47 @@ * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * ***************************************************************************/ -#ifndef _CHATVIEW_H_ -#define _CHATVIEW_H_ +#ifndef CHATVIEW_H_ +#define CHATVIEW_H_ #include +#include "abstractbuffercontainer.h" + class AbstractUiMsg; class Buffer; class ChatLine; class ChatScene; +class MessageFilter; -class ChatView : public QGraphicsView { +class ChatView : public QGraphicsView, public AbstractChatView { Q_OBJECT - public: - ChatView(Buffer *, QWidget *parent = 0); - ~ChatView(); +public: + ChatView(MessageFilter *, QWidget *parent = 0); + ChatView(BufferId bufferId, QWidget *parent = 0); - ChatScene *scene() const; + virtual MsgId lastMsgId() const; + inline ChatScene *scene() const { return _scene; } - public slots: -/* - void clear(); +public slots: + inline virtual void clear() {} + void setBufferForBacklogFetching(BufferId buffer); - void prependMsg(AbstractUiMsg *); - void appendMsg(AbstractUiMsg *); +protected: + virtual void resizeEvent(QResizeEvent *event); - void prependChatLine(ChatLine *); - void appendChatLine(ChatLine *); - void prependChatLines(QList); - void appendChatLines(QList); +protected slots: + virtual void sceneHeightChanged(qreal height); + virtual void verticalScrollbarChanged(int); + virtual void sliderPressed(); + virtual void sliderReleased(); + +private: + void init(MessageFilter *filter); - void setContents(QList); -*/ - private: - ChatScene *_scene; + ChatScene *_scene; }; + #endif