projects
/
quassel.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Allow port numbers up to 65535 for proxies
[quassel.git]
/
src
/
qtui
/
chatview.h
diff --git
a/src/qtui/chatview.h
b/src/qtui/chatview.h
index
7927316
..
e0ea20b
100644
(file)
--- a/
src/qtui/chatview.h
+++ b/
src/qtui/chatview.h
@@
-1,5
+1,5
@@
/***************************************************************************
/***************************************************************************
- * Copyright (C) 2005-0
7 by the Quassel IRC Team
*
+ * Copyright (C) 2005-0
8 by the Quassel Project
*
* devel@quassel-irc.org *
* *
* This program is free software; you can redistribute it and/or modify *
* devel@quassel-irc.org *
* *
* This program is free software; you can redistribute it and/or modify *
@@
-18,41
+18,57
@@
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
***************************************************************************/
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
***************************************************************************/
-#ifndef
_
CHATVIEW_H_
-#define
_
CHATVIEW_H_
+#ifndef CHATVIEW_H_
+#define CHATVIEW_H_
#include <QGraphicsView>
#include <QGraphicsView>
+#include <QTimer>
+
+#include "abstractbuffercontainer.h"
class AbstractUiMsg;
class Buffer;
class ChatLine;
class ChatScene;
class AbstractUiMsg;
class Buffer;
class ChatLine;
class ChatScene;
+class MessageFilter;
-class ChatView : public QGraphicsView {
+class ChatView : public QGraphicsView
, public AbstractChatView
{
Q_OBJECT
Q_OBJECT
- public:
- ChatView(Buffer *, QWidget *parent = 0);
- ~ChatView();
+public:
+ ChatView(MessageFilter *, QWidget *parent = 0);
+ ChatView(BufferId bufferId, QWidget *parent = 0);
+
+ virtual MsgId lastMsgId() const;
+ inline ChatScene *scene() const { return _scene; }
- ChatScene *scene() const;
+public slots:
+ inline virtual void clear() {}
+ void zoomIn();
+ void zoomOut();
+ void zoomNormal();
- public slots:
-/*
- void clear();
+protected:
+ virtual void resizeEvent(QResizeEvent *event);
- void prependMsg(AbstractUiMsg *);
- void appendMsg(AbstractUiMsg *);
+protected slots:
+ virtual inline void sceneRectChanged(const QRectF &rect) { setSceneRect(rect); }
+ virtual void verticalScrollbarChanged(int);
- void prependChatLine(ChatLine *);
-
void appendChatLine(ChatLine *
);
-
void prependChatLines(QList<ChatLine *>
);
-
void appendChatLines(QList<ChatLine *>
);
+private slots:
+
void lastLineChanged(QGraphicsItem *chatLine, qreal offset
);
+
void mouseMoveWhileSelecting(const QPointF &scenePos
);
+
void scrollTimerTimeout(
);
- void setContents(QList<ChatLine *>);
-*/
- private:
- ChatScene *_scene;
+private:
+ void init(MessageFilter *filter);
+
+ ChatScene *_scene;
+ int _lastScrollbarPos;
+ qreal _currentScaleFactor;
+ QTimer _scrollTimer;
+ int _scrollOffset;
};
};
+
#endif
#endif