From ed5963e48eeb141c3eed51d6c4729be7e61bfa19 Mon Sep 17 00:00:00 2001 From: Kevin Smith <git@kismith.co.uk> Date: Tue, 15 Sep 2009 11:24:08 +0100 Subject: Immediately update the Qt roster when items change. diff --git a/Swift/QtUI/Roster/QtTreeWidgetItem.cpp b/Swift/QtUI/Roster/QtTreeWidgetItem.cpp index c9693eb..00a84f3 100644 --- a/Swift/QtUI/Roster/QtTreeWidgetItem.cpp +++ b/Swift/QtUI/Roster/QtTreeWidgetItem.cpp @@ -13,14 +13,17 @@ QtTreeWidgetItem::QtTreeWidgetItem(QtTreeWidgetItem* parentItem) : QObject(), te void QtTreeWidgetItem::setText(const String& text) { displayName_ = P2QSTRING(text); + emit changed(this); } void QtTreeWidgetItem::setStatusText(const String& text) { statusText_ = P2QSTRING(text); + emit changed(this); } void QtTreeWidgetItem::setAvatarPath(const String& path) { avatar_ = QIcon(P2QSTRING(path)); + emit changed(this); } void QtTreeWidgetItem::setStatusShow(StatusShow::Type show) { @@ -35,6 +38,7 @@ void QtTreeWidgetItem::setStatusShow(StatusShow::Type show) { case StatusShow::None: color = 0x7F7F7F;break; } setTextColor(color); + emit changed(this); } void QtTreeWidgetItem::setTextColor(unsigned long color) { -- cgit v0.10.2-6-g49f6