summaryrefslogtreecommitdiff
path: root/plugins/SmileyAdd/src
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/SmileyAdd/src')
-rw-r--r--plugins/SmileyAdd/src/imagecache.cpp28
-rw-r--r--plugins/SmileyAdd/src/main.cpp4
-rw-r--r--plugins/SmileyAdd/src/stdafx.h1
3 files changed, 14 insertions, 19 deletions
diff --git a/plugins/SmileyAdd/src/imagecache.cpp b/plugins/SmileyAdd/src/imagecache.cpp
index 26842e284b..87043a9e26 100644
--- a/plugins/SmileyAdd/src/imagecache.cpp
+++ b/plugins/SmileyAdd/src/imagecache.cpp
@@ -421,34 +421,34 @@ ImageFType::ImageFType(const unsigned id, const CMStringW &file)
{
m_bmp = nullptr;
- FREE_IMAGE_FORMAT fif = fei->FI_GetFileTypeU(file.c_str(), 0);
+ FREE_IMAGE_FORMAT fif = FreeImage_GetFileTypeU(file.c_str(), 0);
if (fif == FIF_UNKNOWN)
- fif = fei->FI_GetFIFFromFilenameU(file.c_str());
+ fif = FreeImage_GetFIFFromFilenameU(file.c_str());
if (fif == FIF_UNKNOWN) return;
- FIBITMAP *dib = fei->FI_LoadU(fif, file.c_str(), 0);
+ FIBITMAP *dib = FreeImage_LoadU(fif, file.c_str(), 0);
if (dib == nullptr) return;
- bool transp = fei->FI_IsTransparent(dib) != 0;
- FREE_IMAGE_TYPE imt = fei->FI_GetImageType(dib);
- unsigned bpp = fei->FI_GetBPP(dib);
+ bool transp = FreeImage_IsTransparent(dib) != 0;
+ FREE_IMAGE_TYPE imt = FreeImage_GetImageType(dib);
+ unsigned bpp = FreeImage_GetBPP(dib);
if (transp && bpp != 32 || imt == FIT_RGBA16) {
- FIBITMAP *tdib = fei->FI_ConvertTo32Bits(dib);
- fei->FI_Unload(dib);
+ FIBITMAP *tdib = FreeImage_ConvertTo32Bits(dib);
+ FreeImage_Unload(dib);
dib = tdib;
}
else if (!transp && bpp > 24) {
- FIBITMAP *tdib = fei->FI_ConvertTo24Bits(dib);
- fei->FI_Unload(dib);
+ FIBITMAP *tdib = FreeImage_ConvertTo24Bits(dib);
+ FreeImage_Unload(dib);
dib = tdib;
}
- m_bmp = fei->FI_CreateHBITMAPFromDIB(dib);
- fei->FI_Unload(dib);
+ m_bmp = FreeImage_CreateHBITMAPFromDIB(dib);
+ FreeImage_Unload(dib);
if (transp)
- fei->FI_Premultiply(m_bmp);
+ FreeImage_Premultiply(m_bmp);
}
ImageFType::~ImageFType()
@@ -550,7 +550,7 @@ ImageBase* AddCacheImage(const CMStringW &file, int index)
img = opt.HQScaling ? (ImageBase*)new ImageType(id, file, index, icoIcl) : (ImageBase*)new IconType(id, file, index, icoIcl);
else if (ext == L"gif")
img = new ImageType(id, file, nullptr);
- else if (fei == nullptr || ext == L"tif" || ext == L"tiff")
+ else if (ext == L"tif" || ext == L"tiff")
img = new ImageType(id, file, nullptr);
else
img = opt.HQScaling ? (ImageBase*)new ImageType(id, file, nullptr) : (ImageBase*)new ImageFType(id, file);
diff --git a/plugins/SmileyAdd/src/main.cpp b/plugins/SmileyAdd/src/main.cpp
index 3a6cfee311..05698d2c75 100644
--- a/plugins/SmileyAdd/src/main.cpp
+++ b/plugins/SmileyAdd/src/main.cpp
@@ -24,8 +24,6 @@ HINSTANCE g_hInst;
HANDLE hEvent1;
HGENMENU hContactMenuItem;
-FI_INTERFACE *fei;
-
int hLangpack;
static const PLUGININFOEX pluginInfoEx =
@@ -91,8 +89,6 @@ extern "C" __declspec(dllexport) int Load(void)
return 1;
}
- CallService(MS_IMG_GETINTERFACE, FI_IF_VERSION, (LPARAM)&fei);
-
InitImageCache();
Icon_Register(g_hInst, MODULENAME, &icon, 1);
diff --git a/plugins/SmileyAdd/src/stdafx.h b/plugins/SmileyAdd/src/stdafx.h
index 227d1744fb..3993c29660 100644
--- a/plugins/SmileyAdd/src/stdafx.h
+++ b/plugins/SmileyAdd/src/stdafx.h
@@ -86,7 +86,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#include "smileyroutines.h"
#include "smltool.h"
-extern FI_INTERFACE *fei;
extern HINSTANCE g_hInst;
extern HNETLIBUSER hNetlibUser;
extern HANDLE hEvent1;