diff options
author | Alvaro Soliverez <alvaro.soliverez@collabora.co.uk> | 2011-08-05 06:57:22 -0700 |
---|---|---|
committer | Alvaro Soliverez <alvaro.soliverez@collabora.co.uk> | 2011-08-05 06:57:22 -0700 |
commit | 433c05ecff8bdf1d290bd678175852f1ea7c82f5 (patch) | |
tree | 5783ee230605faea8ff912374a6489e88e020754 | |
parent | 45f9fc66c60c4ee4eabaf77f5661e856902fb0da (diff) |
Add ServiceNameRole to AccountsModel
-rw-r--r-- | NEWS | 1 | ||||
-rw-r--r-- | TelepathyQt4Yell/Models/accounts-model-item.cpp | 2 | ||||
-rw-r--r-- | TelepathyQt4Yell/Models/accounts-model.cpp | 1 | ||||
-rw-r--r-- | TelepathyQt4Yell/Models/accounts-model.h | 1 |
4 files changed, 5 insertions, 0 deletions
@@ -7,6 +7,7 @@ Enhancements: * Use Tp::AccountSet instead of Tp::AccountManager to monitor accounts in Tpy::AccountsModel * Add fileTransfers to Tpy::ContactCapabilities * Add Capabilities roles to AccountsModelItem + * Add ServiceNameRole to AccountsModel Fixes: * Report the connection status reason using the Connection object if possible diff --git a/TelepathyQt4Yell/Models/accounts-model-item.cpp b/TelepathyQt4Yell/Models/accounts-model-item.cpp index 0f9127f..840f972 100644 --- a/TelepathyQt4Yell/Models/accounts-model-item.cpp +++ b/TelepathyQt4Yell/Models/accounts-model-item.cpp @@ -205,6 +205,8 @@ QVariant AccountsModelItem::data(int role) const return mPriv->mAccount->cmName(); case AccountsModel::ProtocolNameRole: return mPriv->mAccount->protocolName(); + case AccountsModel::ServiceNameRole: + return mPriv->mAccount->serviceName(); case AccountsModel::DisplayNameRole: case Qt::DisplayRole: return mPriv->mAccount->displayName(); diff --git a/TelepathyQt4Yell/Models/accounts-model.cpp b/TelepathyQt4Yell/Models/accounts-model.cpp index 8ff645b..7386059 100644 --- a/TelepathyQt4Yell/Models/accounts-model.cpp +++ b/TelepathyQt4Yell/Models/accounts-model.cpp @@ -98,6 +98,7 @@ void AccountsModel::initialize() roles[EnabledRole] = "enabled"; roles[ConnectionManagerNameRole] = "connectionManager"; roles[ProtocolNameRole] = "protocol"; + roles[ServiceNameRole] = "service"; roles[DisplayNameRole] = "displayName"; roles[IconRole] = "icon"; roles[NicknameRole] = "nickname"; diff --git a/TelepathyQt4Yell/Models/accounts-model.h b/TelepathyQt4Yell/Models/accounts-model.h index 55372fb..8075175 100644 --- a/TelepathyQt4Yell/Models/accounts-model.h +++ b/TelepathyQt4Yell/Models/accounts-model.h @@ -69,6 +69,7 @@ public: EnabledRole, ConnectionManagerNameRole, ProtocolNameRole, + ServiceNameRole, DisplayNameRole, IconRole, NicknameRole, |