diff options
author | Alexandr Akulich <akulichalexander@gmail.com> | 2015-10-11 14:46:39 +0500 |
---|---|---|
committer | Alexandr Akulich <akulichalexander@gmail.com> | 2015-11-20 21:37:40 +0500 |
commit | c6b68774e79e488fc449d25d6a3f975890ae0fb2 (patch) | |
tree | 0533092939e13640f5bd3ed37767437abf741f4e | |
parent | 22ca8bc0db5ae434bd35a5918953967ebf26e375 (diff) |
Services/Chan.I.Group: Removed BaseConnection argument from constructor.
-rw-r--r-- | TelepathyQt/base-channel.cpp | 13 | ||||
-rw-r--r-- | TelepathyQt/base-channel.h | 11 |
2 files changed, 15 insertions, 9 deletions
diff --git a/TelepathyQt/base-channel.cpp b/TelepathyQt/base-channel.cpp index fb557e22..a3794392 100644 --- a/TelepathyQt/base-channel.cpp +++ b/TelepathyQt/base-channel.cpp @@ -1784,8 +1784,8 @@ void BaseChannelChatStateInterface::chatStateChanged(uint contact, uint state) // Chan.I.Group // The BaseChannelGroupInterface code is fully or partially generated by the TelepathyQt-Generator. struct TP_QT_NO_EXPORT BaseChannelGroupInterface::Private { - Private(BaseChannelGroupInterface *parent, BaseConnection *connection) - : connection(connection), + Private(BaseChannelGroupInterface *parent) + : connection(0), selfHandle(0), adaptee(new BaseChannelGroupInterface::Adaptee(parent)) { @@ -2032,9 +2032,9 @@ void BaseChannelGroupInterface::Private::emitMembersChangedSignal(const UIntList /** * Class constructor. */ -BaseChannelGroupInterface::BaseChannelGroupInterface(Tp::BaseConnection *connection) +BaseChannelGroupInterface::BaseChannelGroupInterface() : AbstractChannelInterface(TP_QT_IFACE_CHANNEL_INTERFACE_GROUP), - mPriv(new Private(this, connection)) + mPriv(new Private(this)) { } @@ -2046,6 +2046,11 @@ BaseChannelGroupInterface::~BaseChannelGroupInterface() delete mPriv; } +void BaseChannelGroupInterface::setBaseChannel(BaseChannel *channel) +{ + mPriv->connection = channel->connection(); +} + /** * Return the immutable properties of this interface. * diff --git a/TelepathyQt/base-channel.h b/TelepathyQt/base-channel.h index dda8112c..1af92a04 100644 --- a/TelepathyQt/base-channel.h +++ b/TelepathyQt/base-channel.h @@ -536,15 +536,15 @@ class TP_QT_EXPORT BaseChannelGroupInterface : public AbstractChannelInterface Q_DISABLE_COPY(BaseChannelGroupInterface) public: - static BaseChannelGroupInterfacePtr create(Tp::BaseConnection *connection) + static BaseChannelGroupInterfacePtr create() { - return BaseChannelGroupInterfacePtr(new BaseChannelGroupInterface(connection)); + return BaseChannelGroupInterfacePtr(new BaseChannelGroupInterface()); } template<typename BaseChannelGroupInterfaceSubclass> - static SharedPtr<BaseChannelGroupInterfaceSubclass> create(Tp::BaseConnection *connection) + static SharedPtr<BaseChannelGroupInterfaceSubclass> create() { return SharedPtr<BaseChannelGroupInterfaceSubclass>( - new BaseChannelGroupInterfaceSubclass(connection)); + new BaseChannelGroupInterfaceSubclass()); } virtual ~BaseChannelGroupInterface(); @@ -581,7 +581,8 @@ public: void removeMembers(const Tp::UIntList &contacts, const QString &message, uint reason, DBusError *error); protected: - BaseChannelGroupInterface(Tp::BaseConnection *connection); + BaseChannelGroupInterface(); + void setBaseChannel(BaseChannel *channel); private: void createAdaptor(); |