[Telepathy-commits] [telepathy-qt4/master] Added missing signals to Account class.
Andre Moreira Magalhaes (andrunko)
andre.magalhaes at collabora.co.uk
Tue Jan 13 11:57:47 PST 2009
---
TelepathyQt4/Client/account-internal.h | 6 +++++-
TelepathyQt4/Client/account.cpp | 20 ++++++++++++++++++--
TelepathyQt4/Client/account.h | 6 +++++-
3 files changed, 28 insertions(+), 4 deletions(-)
diff --git a/TelepathyQt4/Client/account-internal.h b/TelepathyQt4/Client/account-internal.h
index 90a83ec..d942c34 100644
--- a/TelepathyQt4/Client/account-internal.h
+++ b/TelepathyQt4/Client/account-internal.h
@@ -94,10 +94,14 @@ Q_SIGNALS:
void displayNameChanged(const QString &);
void iconChanged(const QString &);
void nicknameChanged(const QString &);
- void stateChanged(bool);
+ void normalizedNameChanged(const QString &);
void validityChanged(bool);
+ void stateChanged(bool);
+ void connectsAutomaticallyPropertyChanged(bool);
void parametersChanged(const QVariantMap &);
+ void automaticPresenceChanged(const Telepathy::SimplePresence &) const;
void presenceChanged(const Telepathy::SimplePresence &) const;
+ void requestedPresenceChanged(const Telepathy::SimplePresence &) const;
void avatarChanged(const Telepathy::Avatar &);
void connectionStatusChanged(Telepathy::ConnectionStatus,
Telepathy::ConnectionStatusReason);
diff --git a/TelepathyQt4/Client/account.cpp b/TelepathyQt4/Client/account.cpp
index 494ba39..2ad47db 100644
--- a/TelepathyQt4/Client/account.cpp
+++ b/TelepathyQt4/Client/account.cpp
@@ -189,6 +189,7 @@ void Account::Private::updateProperties(const QVariantMap &props)
if (props.contains("NormalizedName")) {
normalizedName = qdbus_cast<QString>(props["NormalizedName"]);
+ Q_EMIT normalizedNameChanged(normalizedName);
}
if (props.contains("Valid")) {
@@ -204,6 +205,7 @@ void Account::Private::updateProperties(const QVariantMap &props)
if (props.contains("ConnectAutomatically")) {
connectsAutomatically =
qdbus_cast<bool>(props["ConnectAutomatically"]);
+ Q_EMIT connectsAutomaticallyPropertyChanged(connectsAutomatically);
}
if (props.contains("Parameters")) {
@@ -214,6 +216,7 @@ void Account::Private::updateProperties(const QVariantMap &props)
if (props.contains("AutomaticPresence")) {
automaticPresence = qdbus_cast<Telepathy::SimplePresence>(
props["AutomaticPresence"]);
+ Q_EMIT automaticPresenceChanged(automaticPresence);
}
if (props.contains("CurrentPresence")) {
@@ -225,6 +228,7 @@ void Account::Private::updateProperties(const QVariantMap &props)
if (props.contains("RequestedPresence")) {
requestedPresence = qdbus_cast<Telepathy::SimplePresence>(
props["RequestedPresence"]);
+ Q_EMIT requestedPresenceChanged(requestedPresence);
}
if (props.contains("Connection")) {
@@ -504,18 +508,30 @@ Account::Account(AccountManager *am, const QString &objectPath,
SIGNAL(nicknameChanged(const QString &)),
SIGNAL(nicknameChanged(const QString &)));
connect(mPriv,
- SIGNAL(stateChanged(bool)),
- SIGNAL(stateChanged(bool)));
+ SIGNAL(nornalizedNameChanged(const QString &)),
+ SIGNAL(nornalizedNameChanged(const QString &)));
connect(mPriv,
SIGNAL(validityChanged(bool)),
SIGNAL(validityChanged(bool)));
connect(mPriv,
+ SIGNAL(stateChanged(bool)),
+ SIGNAL(stateChanged(bool)));
+ connect(mPriv,
+ SIGNAL(connectsAutomaticallyPropertyChanged(bool)),
+ SIGNAL(connectsAutomaticallyPropertyChanged(bool)));
+ connect(mPriv,
SIGNAL(parametersChanged(const QVariantMap &)),
SIGNAL(parametersChanged(const QVariantMap &)));
connect(mPriv,
+ SIGNAL(automaticPresenceChanged(const Telepathy::SimplePresence &)),
+ SIGNAL(automaticPresenceChanged(const Telepathy::SimplePresence &)));
+ connect(mPriv,
SIGNAL(presenceChanged(const Telepathy::SimplePresence &)),
SIGNAL(presenceChanged(const Telepathy::SimplePresence &)));
connect(mPriv,
+ SIGNAL(requestedPresenceChanged(const Telepathy::SimplePresence &)),
+ SIGNAL(requestedPresenceChanged(const Telepathy::SimplePresence &)));
+ connect(mPriv,
SIGNAL(avatarChanged(const Telepathy::Avatar &)),
SIGNAL(avatarChanged(const Telepathy::Avatar &)));
connect(mPriv,
diff --git a/TelepathyQt4/Client/account.h b/TelepathyQt4/Client/account.h
index 8827ad3..d5b8528 100644
--- a/TelepathyQt4/Client/account.h
+++ b/TelepathyQt4/Client/account.h
@@ -168,10 +168,14 @@ Q_SIGNALS:
void displayNameChanged(const QString &);
void iconChanged(const QString &);
void nicknameChanged(const QString &);
- void stateChanged(bool);
+ void normalizedNameChanged(const QString &);
void validityChanged(bool);
+ void stateChanged(bool);
+ void connectsAutomaticallyPropertyChanged(bool);
void parametersChanged(const QVariantMap &);
+ void automaticPresenceChanged(const Telepathy::SimplePresence &) const;
void presenceChanged(const Telepathy::SimplePresence &) const;
+ void requestedPresenceChanged(const Telepathy::SimplePresence &) const;
void avatarChanged(const Telepathy::Avatar &);
void connectionStatusChanged(Telepathy::ConnectionStatus,
Telepathy::ConnectionStatusReason);
--
1.5.6.5
More information about the Telepathy-commits
mailing list