From dea9c030340e50324eba97c72a27c151bed12e1c Mon Sep 17 00:00:00 2001 From: George Hazan Date: Fri, 26 Jan 2018 17:38:31 +0300 Subject: AdvaImg: - freeimage extracted to the separate library; - FI_INTERFACE removed, all references to it are replaced with direct calls of FreeImage_* functions; - unified project for AdvaImg --- protocols/SkypeWeb/src/main.cpp | 2 -- protocols/SkypeWeb/src/skype_avatars.cpp | 4 +--- protocols/SkypeWeb/src/stdafx.h | 1 - 3 files changed, 1 insertion(+), 6 deletions(-) (limited to 'protocols/SkypeWeb/src') diff --git a/protocols/SkypeWeb/src/main.cpp b/protocols/SkypeWeb/src/main.cpp index 765b40ea7b..1b512abb87 100644 --- a/protocols/SkypeWeb/src/main.cpp +++ b/protocols/SkypeWeb/src/main.cpp @@ -20,7 +20,6 @@ along with this program. If not, see . int hLangpack; HINSTANCE g_hInstance; CLIST_INTERFACE *pcli; -FI_INTERFACE *fii = nullptr; char g_szMirVer[100]; HANDLE g_hCallEvent; CHAT_MANAGER *pci; @@ -58,7 +57,6 @@ extern "C" int __declspec(dllexport) Load(void) mir_getLP(&pluginInfo); pcli = Clist_GetInterface(); pci = Chat_GetInterface(); - CallService(MS_IMG_GETINTERFACE, FI_IF_VERSION, (LPARAM)&fii); Miranda_GetVersionText(g_szMirVer, sizeof(g_szMirVer)); PROTOCOLDESCRIPTOR pd = { 0 }; diff --git a/protocols/SkypeWeb/src/skype_avatars.cpp b/protocols/SkypeWeb/src/skype_avatars.cpp index 056ce171af..11f5535664 100644 --- a/protocols/SkypeWeb/src/skype_avatars.cpp +++ b/protocols/SkypeWeb/src/skype_avatars.cpp @@ -179,9 +179,7 @@ INT_PTR CSkypeProto::SvcSetMyAvatar(WPARAM, LPARAM lParam) mir_ptr data((PBYTE)mir_alloc(length)); if (data != NULL && fread(data, sizeof(BYTE), length, hFile) == length) { - const char *szMime = "image/jpeg"; - if (fii) - szMime = fii->FI_GetFIFMimeType(fii->FI_GetFIFFromFilenameU(path)); + const char *szMime = FreeImage_GetFIFMimeType(FreeImage_GetFIFFromFilenameU(path)); PushRequest(new SetAvatarRequest(data, length, szMime, li), &CSkypeProto::OnSentAvatar); fclose(hFile); diff --git a/protocols/SkypeWeb/src/stdafx.h b/protocols/SkypeWeb/src/stdafx.h index f7166238cc..94abd8398d 100644 --- a/protocols/SkypeWeb/src/stdafx.h +++ b/protocols/SkypeWeb/src/stdafx.h @@ -60,7 +60,6 @@ struct CSkypeProto; extern HINSTANCE g_hInstance; extern char g_szMirVer[]; extern HANDLE g_hCallEvent; -extern FI_INTERFACE *fii; struct SESSION_INFO : public GCSessionInfoBase {}; -- cgit v1.2.3