summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swift/QtUI/Roster/RosterItem.h')
-rw-r--r--Swift/QtUI/Roster/RosterItem.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/Swift/QtUI/Roster/RosterItem.h b/Swift/QtUI/Roster/RosterItem.h
index f7cd804..e0041d2 100644
--- a/Swift/QtUI/Roster/RosterItem.h
+++ b/Swift/QtUI/Roster/RosterItem.h
@@ -1,9 +1,10 @@
#pragma once
#include <QList>
-
+#include <QVariant>
namespace Swift {
- class RosterItem {
+ class RosterItem : public QObject {
+ Q_OBJECT
public:
RosterItem(RosterItem* parent);
~RosterItem();
@@ -11,10 +12,16 @@ namespace Swift {
RosterItem* getParentItem();
int rowCount();
int rowOf(RosterItem* item);
+ int row();
RosterItem* getItem(int row);
+ QVariant data(int role);
+ void setName(QString name);
+ signals:
+ void changed();
private:
QList<RosterItem*> children_;
RosterItem* parent_;
+ QString name_;
};
} \ No newline at end of file