summaryrefslogtreecommitdiffstats
blob: 14b45253f481e4a3dfd5d75428efa65d6a149e63 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#include "RosterItem.h"

namespace Swift {
	
RosterItem::RosterItem(RosterItem* parent) {
	parent_ = parent;
}

RosterItem* RosterItem::getParentItem() {
	return parent_;
}

void RosterItem::addChild(RosterItem* child) {
	children_.append(child);
}

int RosterItem::rowCount() {
	return children_.size();
}

int RosterItem::rowOf(RosterItem* item) {
	return children_.indexOf(item);;
}
	
RosterItem* RosterItem::getItem(int row) {
	return children_[row];
}
}