summaryrefslogtreecommitdiff
path: root/protocols/IcqOscarJ/changeinfo/dlgproc.cpp
diff options
context:
space:
mode:
authorVadim Dashevskiy <watcherhd@gmail.com>2012-06-14 16:22:13 +0000
committerVadim Dashevskiy <watcherhd@gmail.com>2012-06-14 16:22:13 +0000
commitd5d023f683b23fe26ddea93738cb721d532804f0 (patch)
tree21e7398686c7a5d1604d58bfb71ca4329c84be66 /protocols/IcqOscarJ/changeinfo/dlgproc.cpp
parente58823d961a630eb62e60d2ccb443761ba5f1704 (diff)
another portion of "#ifsef Unicode" removal
git-svn-id: http://svn.miranda-ng.org/main/trunk@411 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/IcqOscarJ/changeinfo/dlgproc.cpp')
-rw-r--r--protocols/IcqOscarJ/changeinfo/dlgproc.cpp19
1 files changed, 6 insertions, 13 deletions
diff --git a/protocols/IcqOscarJ/changeinfo/dlgproc.cpp b/protocols/IcqOscarJ/changeinfo/dlgproc.cpp
index 127521eafc..a78fc64016 100644
--- a/protocols/IcqOscarJ/changeinfo/dlgproc.cpp
+++ b/protocols/IcqOscarJ/changeinfo/dlgproc.cpp
@@ -41,19 +41,12 @@ static int DrawTextUtf(HDC hDC, char *text, LPRECT lpRect, UINT uFormat, LPSIZE
{
int res;
- #if defined( _UNICODE )
- WCHAR *tmp = make_unicode_string(text);
- res = DrawTextW(hDC, tmp, -1, lpRect, uFormat);
- if (lpSize)
- GetTextExtentPoint32W(hDC, tmp, strlennull(tmp), lpSize);
- SAFE_FREE((void**)&tmp);
- #else
- // caution, here we change text's contents
- utf8_decode_static(text, (char*)text, strlennull(text) + 1);
- res = DrawTextA(hDC, (char*)text, -1, lpRect, uFormat);
- if (lpSize)
- GetTextExtentPoint32A(hDC, (char*)text, strlennull(text), lpSize);
- #endif
+ WCHAR *tmp = make_unicode_string(text);
+ res = DrawTextW(hDC, tmp, -1, lpRect, uFormat);
+ if (lpSize)
+ GetTextExtentPoint32W(hDC, tmp, strlennull(tmp), lpSize);
+ SAFE_FREE((void**)&tmp);
+
return res;
}