[telepathy-qt4/master] PendingChannelRequest: Use setFinished/setFinishedWithError slots.

Andre Moreira Magalhaes (andrunko) andre.magalhaes at collabora.co.uk
Thu Jun 11 10:05:54 PDT 2009


---
 TelepathyQt4/pending-channel-request.cpp |   15 ++-------------
 TelepathyQt4/pending-channel-request.h   |    3 ---
 2 files changed, 2 insertions(+), 16 deletions(-)

diff --git a/TelepathyQt4/pending-channel-request.cpp b/TelepathyQt4/pending-channel-request.cpp
index ea321a9..b4beebd 100644
--- a/TelepathyQt4/pending-channel-request.cpp
+++ b/TelepathyQt4/pending-channel-request.cpp
@@ -178,10 +178,10 @@ void PendingChannelRequest::onWatcherFinished(QDBusPendingCallWatcher *watcher)
         } else {
             connect(mPriv->channelRequest.data(),
                     SIGNAL(failed(const QString &, const QString &)),
-                    SLOT(onChannelRequestFailed(const QString &, const QString &)));
+                    SLOT(setFinishedWithError(const QString &, const QString &)));
             connect(mPriv->channelRequest.data(),
                     SIGNAL(succeeded()),
-                    SLOT(onChannelRequestSucceeded()));
+                    SLOT(setFinished()));
 
             connect(mPriv->channelRequest->proceed(),
                     SIGNAL(finished(Tp::PendingOperation*)),
@@ -198,17 +198,6 @@ void PendingChannelRequest::onWatcherFinished(QDBusPendingCallWatcher *watcher)
     watcher->deleteLater();
 }
 
-void PendingChannelRequest::onChannelRequestFailed(
-        const QString &errorName, const QString &errorMessage)
-{
-    setFinishedWithError(errorName, errorMessage);
-}
-
-void PendingChannelRequest::onChannelRequestSucceeded()
-{
-    setFinished();
-}
-
 void PendingChannelRequest::onProceedOperationFinished(PendingOperation *op)
 {
     if (op->isError()) {
diff --git a/TelepathyQt4/pending-channel-request.h b/TelepathyQt4/pending-channel-request.h
index e748eaf..86fa3b7 100644
--- a/TelepathyQt4/pending-channel-request.h
+++ b/TelepathyQt4/pending-channel-request.h
@@ -57,9 +57,6 @@ Q_SIGNALS:
 
 private Q_SLOTS:
     void onWatcherFinished(QDBusPendingCallWatcher *watcher);
-    void onChannelRequestFailed(const QString &errorName,
-            const QString &errorMessage);
-    void onChannelRequestSucceeded();
     void onProceedOperationFinished(Tp::PendingOperation *op);
     void onCancelOperationFinished(Tp::PendingOperation *op);
 
-- 
1.5.6.5




More information about the telepathy-commits mailing list