#include <klfenumlistwidget.h>
Classes | |
struct | Item |
Public Slots | |
void | addItem (const QString &s, const QVariant &data=QVariant()) |
void | removeItem (int i) |
void | insertItem (int i, const QString &s, const QVariant &data=QVariant()) |
void | setItems (const QStringList &slist, const QVariantList &datalist=QVariantList()) |
Signals | |
void | itemActivated (const QString &s, const QVariant &data) |
void | itemActivated (int i, const QString &s, const QVariant &data) |
Public Member Functions | |
KLFEnumListWidget (QWidget *parent) | |
virtual | ~KLFEnumListWidget () |
int | itemCount () const |
QString | itemAt (int i) const |
QVariant | itemDataAt (int i) const |
QStringList | itemList () const |
QVariantList | itemDataList () const |
Protected Member Functions | |
virtual void | updateLabelText () |
Protected Attributes | |
QList< Item > | pItems |
Definition at line 34 of file klfenumlistwidget.h.
KLFEnumListWidget::KLFEnumListWidget | ( | QWidget * | parent | ) |
Definition at line 30 of file klfenumlistwidget.cpp.
KLFEnumListWidget::~KLFEnumListWidget | ( | ) | [virtual] |
Definition at line 39 of file klfenumlistwidget.cpp.
void KLFEnumListWidget::addItem | ( | const QString & | s, |
const QVariant & | data = QVariant() |
||
) | [inline, slot] |
Definition at line 54 of file klfenumlistwidget.h.
void KLFEnumListWidget::insertItem | ( | int | i, |
const QString & | s, | ||
const QVariant & | data = QVariant() |
||
) | [slot] |
Definition at line 85 of file klfenumlistwidget.cpp.
References QList::insert(), pItems, and updateLabelText().
void KLFEnumListWidget::itemActivated | ( | const QString & | s, |
const QVariant & | data | ||
) | [signal] |
void KLFEnumListWidget::itemActivated | ( | int | i, |
const QString & | s, | ||
const QVariant & | data | ||
) | [signal] |
QString KLFEnumListWidget::itemAt | ( | int | i | ) | const |
Definition at line 43 of file klfenumlistwidget.cpp.
References pItems, and QList::size().
int KLFEnumListWidget::itemCount | ( | ) | const [inline] |
Definition at line 41 of file klfenumlistwidget.h.
QVariant KLFEnumListWidget::itemDataAt | ( | int | i | ) | const |
Definition at line 50 of file klfenumlistwidget.cpp.
References pItems, and QList::size().
QVariantList KLFEnumListWidget::itemDataList | ( | ) | const |
Definition at line 65 of file klfenumlistwidget.cpp.
References pItems, and QList::size().
QStringList KLFEnumListWidget::itemList | ( | ) | const |
Definition at line 57 of file klfenumlistwidget.cpp.
References pItems, and QList::size().
void KLFEnumListWidget::removeItem | ( | int | i | ) | [slot] |
Definition at line 75 of file klfenumlistwidget.cpp.
References pItems, QList::removeAt(), QList::size(), and updateLabelText().
void KLFEnumListWidget::setItems | ( | const QStringList & | slist, |
const QVariantList & | datalist = QVariantList() |
||
) | [slot] |
Definition at line 93 of file klfenumlistwidget.cpp.
References QList::clear(), KLF_FUNC_NAME, pItems, QList::size(), and updateLabelText().
void KLFEnumListWidget::updateLabelText | ( | ) | [protected, virtual] |
Definition at line 110 of file klfenumlistwidget.cpp.
References QString::number(), pItems, and QList::size().
Referenced by insertItem(), removeItem(), and setItems().
QList<Item> KLFEnumListWidget::pItems [protected] |
Definition at line 70 of file klfenumlistwidget.h.
Referenced by insertItem(), itemAt(), itemDataAt(), itemDataList(), itemList(), removeItem(), setItems(), and updateLabelText().