summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKevin Smith <git@kismith.co.uk>2009-08-18 06:50:09 (GMT)
committerKevin Smith <git@kismith.co.uk>2009-08-18 06:50:09 (GMT)
commit666ad146312a1c8abdefe8bba5582fd9ac042700 (patch)
treea895bd8435c853d113b63aeabe2692dd554e630e /Swift/QtUI/Roster/QtTreeWidgetItem.cpp
parent19cc57c75a495b73d16e0932b77a6e2d9fbdc4e3 (diff)
downloadswift-contrib-666ad146312a1c8abdefe8bba5582fd9ac042700.zip
swift-contrib-666ad146312a1c8abdefe8bba5582fd9ac042700.tar.bz2
Include a (dummy) presence icon in roster entries.
Diffstat (limited to 'Swift/QtUI/Roster/QtTreeWidgetItem.cpp')
-rw-r--r--Swift/QtUI/Roster/QtTreeWidgetItem.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/Swift/QtUI/Roster/QtTreeWidgetItem.cpp b/Swift/QtUI/Roster/QtTreeWidgetItem.cpp
index 7b4d83a..e49c87f 100644
--- a/Swift/QtUI/Roster/QtTreeWidgetItem.cpp
+++ b/Swift/QtUI/Roster/QtTreeWidgetItem.cpp
@@ -139,10 +139,15 @@ QVariant QtTreeWidgetItem::data(int role) {
case Qt::BackgroundColorRole: return backgroundColor_;
case StatusTextRole: return statusText_;
case AvatarRole: return avatar_;
+ case PresenceIconRole: return getPresenceIcon();
default: return QVariant();
}
}
+QIcon QtTreeWidgetItem::getPresenceIcon() {
+ return QIcon(":/icons/online.png");
+}
+
bool QtTreeWidgetItem::isContact() {
return children_.size() == 0;
}