diff options
author | Vadim Dashevskiy <watcherhd@gmail.com> | 2012-07-29 12:02:39 +0000 |
---|---|---|
committer | Vadim Dashevskiy <watcherhd@gmail.com> | 2012-07-29 12:02:39 +0000 |
commit | 837ba88833d864c06ee5d6110a570387a1f37d48 (patch) | |
tree | 722331fe8d20c8e50fee0d2a66c94ab152f64b91 /plugins | |
parent | 4579351044c7c214e44c35816a9ac0934b7ecdf4 (diff) |
Skype: updated to the latest sources
git-svn-id: http://svn.miranda-ng.org/main/trunk@1240 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/!NotAdopted/Skype/Skype_protocol.dsp | 2 | ||||
-rw-r--r-- | plugins/!NotAdopted/Skype/contacts.c | 6 | ||||
-rw-r--r-- | plugins/!NotAdopted/Skype/debug.c | 2 | ||||
-rw-r--r-- | plugins/!NotAdopted/Skype/skype.c | 11 | ||||
-rw-r--r-- | plugins/!NotAdopted/Skype/skypeapi.c | 6 |
5 files changed, 20 insertions, 7 deletions
diff --git a/plugins/!NotAdopted/Skype/Skype_protocol.dsp b/plugins/!NotAdopted/Skype/Skype_protocol.dsp index 3c9191838e..23710dadd3 100644 --- a/plugins/!NotAdopted/Skype/Skype_protocol.dsp +++ b/plugins/!NotAdopted/Skype/Skype_protocol.dsp @@ -82,7 +82,7 @@ BSC32=bscmake.exe # ADD BSC32 /nologo
LINK32=xilink6.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib comctl32.lib Rpcrt4.lib /nologo /dll /debug /machine:I386 /out:"../../../miranda-testaim/Miranda/plugins/Skype.dll" /pdbtype:sept
+# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib comctl32.lib Rpcrt4.lib /nologo /dll /debug /machine:I386 /out:"../../bin/debug/plugins/Skype.dll" /pdbtype:sept
# SUBTRACT LINK32 /map
!ELSEIF "$(CFG)" == "Skype_protocol - Win32 Debug UNICODE"
diff --git a/plugins/!NotAdopted/Skype/contacts.c b/plugins/!NotAdopted/Skype/contacts.c index c83d3294a1..45df24821f 100644 --- a/plugins/!NotAdopted/Skype/contacts.c +++ b/plugins/!NotAdopted/Skype/contacts.c @@ -262,8 +262,10 @@ int __cdecl PrebuildContactMenu(WPARAM wParam, LPARAM lParam) { if (DBGetContactSettingByte((HANDLE)wParam, SKYPE_PROTONAME, "ChatRoom", 0)==0)
mi.flags ^= CMIF_HIDDEN;
mi.flags |= CMIM_FLAGS;
- CallService(MS_CLIST_MODIFYMENUITEM, (WPARAM)(HANDLE)hMenuFileTransferItem,(LPARAM)&mi);
-
+ CallService(MS_CLIST_MODIFYMENUITEM, (WPARAM)(HANDLE)hMenuFileTransferItem,(LPARAM)&mi);
+ }
+
+ if (protocol>=5 || bIsImoproxy) {
mi=ChatInitItem();
if (DBGetContactSettingByte(NULL, SKYPE_PROTONAME, "UseGroupchat", 0) &&
DBGetContactSettingByte((HANDLE)wParam, SKYPE_PROTONAME, "ChatRoom", 0)==0)
diff --git a/plugins/!NotAdopted/Skype/debug.c b/plugins/!NotAdopted/Skype/debug.c index a1267d8d8a..a5d7067e8e 100644 --- a/plugins/!NotAdopted/Skype/debug.c +++ b/plugins/!NotAdopted/Skype/debug.c @@ -18,7 +18,7 @@ extern char g_szProtoName[];
static CRITICAL_SECTION m_WriteFileMutex;
-static FILE *m_fpLogFile = INVALID_HANDLE_VALUE;
+static FILE *m_fpLogFile = NULL;
static char *m_szLogBuf = NULL;
static DWORD m_iBufSize = 0;
diff --git a/plugins/!NotAdopted/Skype/skype.c b/plugins/!NotAdopted/Skype/skype.c index 1aea600d3f..ea35153860 100644 --- a/plugins/!NotAdopted/Skype/skype.c +++ b/plugins/!NotAdopted/Skype/skype.c @@ -799,7 +799,7 @@ void __cdecl SkypeSystemInit(char *dummy) { SkypeSend ("CREATE APPLICATION libpurple_typing");
testfor ("CREATE APPLICATION libpurple_typing", 2000);
}
- if (protocol>=5) {
+ if (protocol>=5 || bIsImoproxy) {
SearchUsersWaitingMyAuthorization(NULL);
if (DBGetContactSettingByte(NULL, SKYPE_PROTONAME, "UseGroupchat", 0))
SearchRecentChats(NULL);
@@ -1127,6 +1127,11 @@ void FetchMessageThread(fetchmsg_arg *pargs) { if (ci.pszVal) miranda_sys_free (ci.pszVal);
}
free_nonutf_tchar_string((void*)gcd.ptszID);
+ if (!args.bDontMarkSeen)
+ {
+ MsgList_Add (pre.lParam, INVALID_HANDLE_VALUE);
+ SkypeSend("SET %s %s SEEN", cmdMessage, args.msgnum);
+ }
__leave;
}
if (!strcmp(type,"LEFT") || (bAddedMembers = strcmp(type,"ADDEDMEMBERS")==0))
@@ -1165,7 +1170,7 @@ void FetchMessageThread(fetchmsg_arg *pargs) { if (!CallService(MS_CONTACT_GETCONTACTINFO,0,(LPARAM)&ci)) gce.ptszNick=ci.pszVal;
else gce.ptszNick=gce.ptszUID;
- CallService(MS_GC_EVENT, 0, (LPARAM)&gce);
+ CallServiceSync(MS_GC_EVENT, 0, (LPARAM)&gce);
free_nonutf_tchar_string((void*)gce.ptszUID);
if (ci.pszVal) miranda_sys_free (ci.pszVal);
}
@@ -3431,7 +3436,7 @@ int __declspec( dllexport ) Unload(void) }
SkypeMsgCleanup();
- WSACleanup();
+ //WSACleanup();
FreeVSApi();
UnhookEvents();
UnhookEvent(hChatEvent);
diff --git a/plugins/!NotAdopted/Skype/skypeapi.c b/plugins/!NotAdopted/Skype/skypeapi.c index 2a6eb1b76e..e26be6e6d2 100644 --- a/plugins/!NotAdopted/Skype/skypeapi.c +++ b/plugins/!NotAdopted/Skype/skypeapi.c @@ -1463,6 +1463,12 @@ static int _ConnectToSkypeAPI(char *path, int iStart) { }
for ( ;; ) {
char *ptr = SkypeRcv ("CONNSTATUS", INFINITE);
+ if (!ptr)
+ {
+ AttachStatus=SKYPECONTROLAPI_ATTACH_NOT_AVAILABLE;
+ return -1;
+ }
+
if (strcmp (ptr+11, "CONNECTING"))
{
free (ptr);
|