X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fqtui%2Fnicklistwidget.h;h=8c2660529138ae9ddaf6ef3f68d9b5ddd290f23a;hp=579d8fbf564d32ca59708d9ca216b422de47d85f;hb=1b2d3ea62867220d7bffc3b23dda1dc14d429007;hpb=e671e9da1edaab37ec403f575979f9a92a766e9a diff --git a/src/qtui/nicklistwidget.h b/src/qtui/nicklistwidget.h index 579d8fbf..8c266052 100644 --- a/src/qtui/nicklistwidget.h +++ b/src/qtui/nicklistwidget.h @@ -1,11 +1,11 @@ /*************************************************************************** - * Copyright (C) 2005-07 by the Quassel IRC Team * + * Copyright (C) 2005-08 by the Quassel Project * * devel@quassel-irc.org * * * * This program is free software; you can redistribute it and/or modify * * it under the terms of the GNU General Public License as published by * * the Free Software Foundation; either version 2 of the License, or * - * (at your option) any later version. * + * (at your option) version 3. * * * * This program is distributed in the hope that it will be useful, * * but WITHOUT ANY WARRANTY; without even the implied warranty of * @@ -22,25 +22,36 @@ #define _NICKLISTWIDGET_H_ #include "ui_nicklistwidget.h" +#include "abstractitemview.h" + +#include "types.h" #include +#include "buffermodel.h" + class Buffer; class NickView; -class NickListWidget : public QWidget { +class NickListWidget : public AbstractItemView { Q_OBJECT - public: - NickListWidget(QWidget *parent = 0); +public: + NickListWidget(QWidget *parent = 0); - public slots: - void setBuffer(Buffer *); +protected: + virtual QSize sizeHint() const; - private: - Ui::NickListWidget ui; - QHash nickViews; +protected slots: + virtual void currentChanged(const QModelIndex ¤t, const QModelIndex &previous); + virtual void rowsAboutToBeRemoved(const QModelIndex &parent, int start, int end); +private slots: + void removeBuffer(BufferId bufferId); + +private: + Ui::NickListWidget ui; + QHash nickViews; }; #endif