diff options
Diffstat (limited to 'kbiff/status.h')
-rw-r--r-- | kbiff/status.h | 59 |
1 files changed, 59 insertions, 0 deletions
diff --git a/kbiff/status.h b/kbiff/status.h new file mode 100644 index 0000000..8c05ad3 --- /dev/null +++ b/kbiff/status.h @@ -0,0 +1,59 @@ +/* + * status.h + * Copyright (C) 1999 Kurt Granroth <granroth@kde.org> + * + * This file contains the declaration of the KBiffStatus + * widget. + * + * $Id$ + */ +#ifndef KBIFFSTATUS_H +#define KBIFFSTATUS_H + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <qframe.h> +#include <qlist.h> +#include <qstring.h> + +class QListView; +class QPoint; + +class KBiffStatusItem : QObject +{ + Q_OBJECT +public: + KBiffStatusItem(const QString& mailbox, const int num_new); + KBiffStatusItem(const QString& mailbox, const int num_new,const int num_cur); + virtual ~KBiffStatusItem(); + + QString mailbox() const { return _mailbox; } + QString newMessages() const { return _newMessages; } + QString curMessages() const { return _curMessages; } + +protected: + QString _mailbox; + QString _newMessages; + QString _curMessages; +}; + +typedef QList<KBiffStatusItem> KBiffStatusList; +typedef QListIterator<KBiffStatusItem> KBiffStatusListIterator; + +class KBiffStatus : public QFrame +{ + Q_OBJECT +public: + KBiffStatus(QWidget *parent, const QString& profile, const KBiffStatusList& list); + virtual ~KBiffStatus(); + + void updateListView(const KBiffStatusList& list); + void popup(const QPoint& pos); + +protected: + QListView *_listView; +}; + +#endif // KBIFFSTATUS_H |