fixing the creating of new buffers in the client. bye bye Client::buffer(BufferId)
[quassel.git] / src / qtui / chatview.h
index b9c1892..998d9fc 100644 (file)
@@ -34,32 +34,30 @@ class MessageFilter;
 class ChatView : public QGraphicsView, public AbstractChatView {
   Q_OBJECT
 
-  public:
-    ChatView(MessageFilter *, QWidget *parent = 0);
-    ChatView(Buffer *, QWidget *parent = 0);
-    ~ChatView();
-
-    ChatScene *scene() const;
-
-  public slots:
-
-    void clear();
-
-    void setBufferForBacklogFetching(BufferId buffer);
-
-  protected:
-    virtual void resizeEvent(QResizeEvent *event);
-
-  protected slots:
-    virtual void sceneHeightChanged(qreal height);
-    virtual void verticalScrollbarChanged(int);
-    virtual void sliderPressed();
-    virtual void sliderReleased();
-
-  private:
-    void init(MessageFilter *filter);
-
-    ChatScene *_scene;
+public:
+  ChatView(MessageFilter *, QWidget *parent = 0);
+  ChatView(BufferId bufferId, QWidget *parent = 0);
+
+  virtual MsgId lastMsgId() const;
+  inline ChatScene *scene() const { return _scene; }
+
+public slots:
+  inline virtual void clear() {}
+  void setBufferForBacklogFetching(BufferId buffer);
+
+protected:
+  virtual void resizeEvent(QResizeEvent *event);
+
+protected slots:
+  virtual void sceneHeightChanged(qreal height);
+  virtual void verticalScrollbarChanged(int);
+  virtual void sliderPressed();
+  virtual void sliderReleased();
+  
+private:
+  void init(MessageFilter *filter);
+
+  ChatScene *_scene;
 };