X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fqtui%2Fchatscene.h;h=5f8057ab1def3fd39e4e4471b48ffad406542d77;hp=8122872fcdfaadd2b2b38fafa7dd684bd501bea2;hb=920feae12b62b749299014ce85241165e09b7f4b;hpb=9e0b5872dcf290e375c46c016f951c6ea780fcc0 diff --git a/src/qtui/chatscene.h b/src/qtui/chatscene.h index 8122872f..5f8057ab 100644 --- a/src/qtui/chatscene.h +++ b/src/qtui/chatscene.h @@ -21,10 +21,9 @@ #ifndef _CHATSCENE_H_ #define _CHATSCENE_H_ +#include #include -#include "messagemodel.h" - class AbstractUiMsg; class Buffer; class ChatItem; @@ -35,22 +34,26 @@ class ChatScene : public QGraphicsScene { Q_OBJECT public: - ChatScene(MessageModel *model, QObject *parent); + ChatScene(QAbstractItemModel *model, QObject *parent); virtual ~ChatScene(); Buffer *buffer() const; - inline MessageModel *model() const { return _model; } + inline QAbstractItemModel *model() const { return _model; } public slots: void setWidth(int); - protected slots: + signals: + void heightChanged(int height); + protected slots: + void rowsInserted(const QModelIndex &, int, int); void mousePressEvent ( QGraphicsSceneMouseEvent * mouseEvent ); private: - int _width; - MessageModel *_model; + int _width, _height; + int _timestampWidth, _senderWidth; + QAbstractItemModel *_model; QList _lines; };