00001
00023 #ifndef _TelepathyQt_handled_channel_notifier_h_HEADER_GUARD_
00024 #define _TelepathyQt_handled_channel_notifier_h_HEADER_GUARD_
00025
00026 #ifndef IN_TP_QT_HEADER
00027 #error IN_TP_QT_HEADER
00028 #endif
00029
00030 #include <TelepathyQt/Channel>
00031 #include <TelepathyQt/Types>
00032
00033 #include <QObject>
00034
00035 namespace Tp
00036 {
00037
00038 class ChannelRequestHints;
00039 class RequestTemporaryHandler;
00040
00041 class TP_QT_EXPORT HandledChannelNotifier : public QObject
00042 {
00043 Q_OBJECT
00044 Q_DISABLE_COPY(HandledChannelNotifier)
00045
00046 public:
00047 ~HandledChannelNotifier();
00048
00049 ChannelPtr channel() const;
00050
00051 Q_SIGNALS:
00052 void handledAgain(const QDateTime &userActionTime, const Tp::ChannelRequestHints &requestHints);
00053
00054 protected:
00055 #if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
00056 void connectNotify(const QMetaMethod &signal);
00057 #else
00058 void connectNotify(const char *signal);
00059 #endif
00060
00061 private Q_SLOTS:
00062 TP_QT_NO_EXPORT void onChannelReceived(const Tp::ChannelPtr &channel,
00063 const QDateTime &userActionTime, const Tp::ChannelRequestHints &requestHints);
00064 TP_QT_NO_EXPORT void onChannelInvalidated();
00065
00066 private:
00067 friend class PendingChannel;
00068
00069 HandledChannelNotifier(const ClientRegistrarPtr &cr,
00070 const SharedPtr<RequestTemporaryHandler> &handler);
00071
00072 struct Private;
00073 friend struct Private;
00074 Private *mPriv;
00075 };
00076
00077 }
00078
00079 #endif