X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fqtui%2Fchatscene.h;h=41fb51a97c2f6c43a8f177f8a406a3a902365713;hp=6a80f6c7886f6f9b3d05cb14e0c884b8b28fe9fd;hb=db511df7b183771ae444f14d0aca42381ee0ae37;hpb=7e76b93191c8f19c24709f36992c99f8ee9d508d diff --git a/src/qtui/chatscene.h b/src/qtui/chatscene.h index 6a80f6c7..41fb51a9 100644 --- a/src/qtui/chatscene.h +++ b/src/qtui/chatscene.h @@ -62,10 +62,10 @@ public: enum ClickMode { NoClick, + DragStartClick, SingleClick, DoubleClick, - TripleClick, - DragStartClick + TripleClick }; ChatScene(QAbstractItemModel *model, const QString &idString, qreal width, ChatView *parent); @@ -81,10 +81,11 @@ public: ChatView *chatView() const; ChatItem *chatItemAt(const QPointF &pos) const; + inline ChatLine *chatLine(int row) { return (row < _lines.count()) ? _lines[row] : 0; } - inline bool isSingleBufferScene() const { return _singleBufferScene; } + inline bool isSingleBufferScene() const { return _singleBufferId.isValid(); } + inline BufferId singleBufferId() const { return _singleBufferId; } bool containsBuffer(const BufferId &id) const; - inline ChatLine *chatLine(int row) { return (row < _lines.count()) ? _lines[row] : 0; } ColumnHandleItem *firstColumnHandle() const; ColumnHandleItem *secondColumnHandle() const; @@ -155,7 +156,7 @@ private: QString _idString; QAbstractItemModel *_model; QList _lines; - bool _singleBufferScene; + BufferId _singleBufferId; // calls to QChatScene::sceneRect() are very expensive. As we manage the scenerect ourselves // we store the size in a member variable.