diff options
author | Alexander Lantsev <aunsane@gmail.com> | 2013-07-05 09:22:35 +0000 |
---|---|---|
committer | Alexander Lantsev <aunsane@gmail.com> | 2013-07-05 09:22:35 +0000 |
commit | b72e59934d6d3629e5d01572aff4516895439888 (patch) | |
tree | 2f5b5c4cd228e1896811b122bbe4fc3d312ecf9d /protocols/Skype/src/skype_transfers.cpp | |
parent | e82fece5a1e77d9394d94b84d8699b38d978b107 (diff) |
Skype:
- temporary disabled multiple file transfer (it send olny first file)
- fixed duplication on history sync
git-svn-id: http://svn.miranda-ng.org/main/trunk@5238 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Skype/src/skype_transfers.cpp')
-rw-r--r-- | protocols/Skype/src/skype_transfers.cpp | 40 |
1 files changed, 27 insertions, 13 deletions
diff --git a/protocols/Skype/src/skype_transfers.cpp b/protocols/Skype/src/skype_transfers.cpp index f99d439ffa..90d1440f4c 100644 --- a/protocols/Skype/src/skype_transfers.cpp +++ b/protocols/Skype/src/skype_transfers.cpp @@ -23,13 +23,15 @@ void CSkypeProto::OnTransferChanged(const TransferRef &transfer, int prop) {
Transfer::FAILUREREASON reason;
- SEBinary guid;
+ /*SEBinary guid;
transfer->GetPropChatmsgGuid(guid);
MessageRef msgRef;
this->GetMessageByGuid(guid, msgRef);
- uint oid = msgRef->getOID();
+ uint oid = msgRef->getOID();*/
+
+ uint oid = transfer->getOID();
SEString data;
transfer->GetPropPartnerHandle(data);
@@ -69,13 +71,7 @@ void CSkypeProto::OnTransferChanged(const TransferRef &transfer, int prop) {
SEString data;
- SEBinary guid;
- transfer->GetPropChatmsgGuid(guid);
-
- MessageRef msgRef;
- this->GetMessageByGuid(guid, msgRef);
-
- uint oid = msgRef->getOID();
+ uint oid = transfer->getOID();
PROTOFILETRANSFERSTATUS pfts = {0};
pfts.cbSize = sizeof(pfts);
@@ -107,7 +103,7 @@ void CSkypeProto::OnTransferChanged(const TransferRef &transfer, int prop) void CSkypeProto::OnFileEvent(const ConversationRef &conversation, const MessageRef &message)
{
SEString data;
- bool isRecvFiles = false;
+ //bool isRecvFiles = false;
Transfer::TYPE transferType;
Transfer::STATUS transferStatus;
@@ -132,10 +128,28 @@ void CSkypeProto::OnFileEvent(const ConversationRef &conversation, const Message transfer->GetPropType(transferType);
if (transferType == Transfer::INCOMING)
{
- isRecvFiles = true;
+ //isRecvFiles = true;
this->transferList.append(transfer);
transfer.fetch();
+
+ uint timestamp;
+ message->GetPropTimestamp(timestamp);
+
+ ContactRef author;
+ message->GetPropAuthor(data);
+ this->GetContact(data, author);
+
+ HANDLE hContact = this->AddContact(author, true);
+
+ PROTORECVFILET pre = {0};
+ pre.flags = PREF_TCHAR;
+ pre.fileCount = transfers.size();
+ pre.timestamp = timestamp;
+ pre.tszDescription = L"";
+ pre.ptszFiles = files;
+ pre.lParam = (LPARAM)transfer->getOID();
+ ::ProtoChainRecvFile(hContact, &pre);
}
else if (transferType == Transfer::PLACEHOLDER)
{
@@ -144,7 +158,7 @@ void CSkypeProto::OnFileEvent(const ConversationRef &conversation, const Message }
}
}
- files[transfers.size()] = NULL;
+ /*files[transfers.size()] = NULL;
if (isRecvFiles)
{
@@ -165,5 +179,5 @@ void CSkypeProto::OnFileEvent(const ConversationRef &conversation, const Message pre.ptszFiles = files;
pre.lParam = (LPARAM)message->getOID();
::ProtoChainRecvFile(hContact, &pre);
- }
+ }*/
}
\ No newline at end of file |