[SCM] ktp-accounts-kcm packaging branch, master, updated. debian/15.12.1-1-1157-gc4589c5
Maximiliano Curia
maxy at moszumanska.debian.org
Fri May 27 23:59:56 UTC 2016
Gitweb-URL: http://git.debian.org/?p=pkg-kde/applications/ktp-accounts-kcm.git;a=commitdiff;h=3408aea
The following commit has been merged in the master branch:
commit 3408aea96247f49648a3f3c4d207e4c6c76a0c71
Author: Daniele E. Domenichelli <daniele.domenichelli at gmail.com>
Date: Sun Sep 18 15:18:52 2011 +0100
Add ConnectionProtocolNameRole to AccountsListModel
---
src/account-item.cpp | 5 +++++
src/account-item.h | 1 +
src/accounts-list-model.cpp | 5 +++++
src/accounts-list-model.h | 3 ++-
4 files changed, 13 insertions(+), 1 deletion(-)
diff --git a/src/account-item.cpp b/src/account-item.cpp
index 033ac44..471a436 100644
--- a/src/account-item.cpp
+++ b/src/account-item.cpp
@@ -136,6 +136,11 @@ const QString AccountItem::connectionStatusReason() const
}
}
+const QString AccountItem::connectionProtocolName() const
+{
+ return m_account->protocolName();
+}
+
void AccountItem::generateIcon()
{
kDebug();
diff --git a/src/account-item.h b/src/account-item.h
index 809b93f..28adfd5 100644
--- a/src/account-item.h
+++ b/src/account-item.h
@@ -47,6 +47,7 @@ public:
const QString connectionStateString() const;
const KIcon connectionStateIcon() const;
const QString connectionStatusReason() const;
+ const QString connectionProtocolName() const;
public Q_SLOTS:
void onTitleForCustomPages(QString, QList<QString>);
diff --git a/src/accounts-list-model.cpp b/src/accounts-list-model.cpp
index e7bbeca..3e8f707 100644
--- a/src/accounts-list-model.cpp
+++ b/src/accounts-list-model.cpp
@@ -98,6 +98,11 @@ QVariant AccountsListModel::data(const QModelIndex &index, int role) const
case AccountsListModel::ConnectionErrorMessageDisplayRole:
data = QVariant(m_accounts.at(index.row())->connectionStatusReason());
break;
+
+ case AccountsListModel::ConnectionProtocolNameRole:
+ data = QVariant(m_accounts.at(index.row())->connectionProtocolName());
+ break;
+
default:
break;
}
diff --git a/src/accounts-list-model.h b/src/accounts-list-model.h
index a2339b2..1480191 100644
--- a/src/accounts-list-model.h
+++ b/src/accounts-list-model.h
@@ -36,7 +36,8 @@ public:
enum Roles {
ConnectionStateDisplayRole = Qt::UserRole+1,
ConnectionStateIconRole = Qt::UserRole+2,
- ConnectionErrorMessageDisplayRole = Qt::UserRole+3
+ ConnectionErrorMessageDisplayRole = Qt::UserRole+3,
+ ConnectionProtocolNameRole = Qt::UserRole+4
};
explicit AccountsListModel(QObject *parent = 0);
--
ktp-accounts-kcm packaging
More information about the pkg-kde-commits
mailing list