From 297626e55974e9082f0fd76b98050fc291b1e3f3 Mon Sep 17 00:00:00 2001 From: Alexander Lantsev Date: Fri, 5 Apr 2013 16:08:13 +0000 Subject: - first approach of file transferring git-svn-id: http://svn.miranda-ng.org/main/trunk@4317 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/Skype/src/skype_subclassing.cpp | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) (limited to 'protocols/Skype/src/skype_subclassing.cpp') diff --git a/protocols/Skype/src/skype_subclassing.cpp b/protocols/Skype/src/skype_subclassing.cpp index 10bdecf9d5..2c24252fa7 100644 --- a/protocols/Skype/src/skype_subclassing.cpp +++ b/protocols/Skype/src/skype_subclassing.cpp @@ -44,6 +44,11 @@ CMessage* CSkype::newMessage(int oid) return new CMessage(oid, this); } +CTransfer* CSkype::newTransfer(int oid) +{ + return new CTransfer(oid, this); +} + CContactSearch* CSkype::newContactSearch(int oid) { return new CContactSearch(oid, this); @@ -479,4 +484,24 @@ void CConversation::SetOnMessageReceivedCallback(OnMessageReceived callback, CSk // CMessage -CMessage::CMessage(unsigned int oid, SERootObject* root) : Message(oid, root) { } \ No newline at end of file +CMessage::CMessage(unsigned int oid, SERootObject* root) : Message(oid, root) { } + +// CTransfer + +CTransfer::CTransfer(unsigned int oid, SERootObject* root) : Transfer(oid, root) +{ + this->proto = NULL; + this->transferCallback = NULL; +} + +void CTransfer::SetOnTransferCallback(OnTransfer callback, CSkypeProto* proto) +{ + this->proto = proto; + this->transferCallback = callback; +} + +void CTransfer::OnChange(int prop) +{ + if (this->proto) + (proto->*transferCallback)(prop, this->ref()); +} \ No newline at end of file -- cgit v1.2.3