summaryrefslogtreecommitdiff
path: root/plugins/FingerPrintModPlus/src/utilities.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-07-29 19:03:51 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-07-29 19:03:51 +0000
commitdd96e20eb908dbbecf1a17fdeee0c44ed8b3a974 (patch)
treeebd667510913aa2bedef89a8d794a74eeda6e5be /plugins/FingerPrintModPlus/src/utilities.cpp
parent66357371399956ad19ab667d3c2d49bfc7ea0095 (diff)
slightly rewritten finger
git-svn-id: http://svn.miranda-ng.org/main/trunk@1244 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/FingerPrintModPlus/src/utilities.cpp')
-rw-r--r--plugins/FingerPrintModPlus/src/utilities.cpp18
1 files changed, 3 insertions, 15 deletions
diff --git a/plugins/FingerPrintModPlus/src/utilities.cpp b/plugins/FingerPrintModPlus/src/utilities.cpp
index cd275caf77..5b623af54b 100644
--- a/plugins/FingerPrintModPlus/src/utilities.cpp
+++ b/plugins/FingerPrintModPlus/src/utilities.cpp
@@ -283,21 +283,9 @@ static LRESULT ControlAddStringUtf(HWND ctrl, DWORD msg, LPCSTR szString)
LPSTR szItem = TranslateUtfStatic(szString, str, MAX_PATH);
LRESULT item = -1;
- if (gbUnicodeAPI)
- {
- LPWSTR wItem = make_unicode_string(szItem);
-
- item = SendMessageW(ctrl, msg, 0, (LPARAM)wItem);
- SAFE_FREE(wItem);
- }
- else
- {
- size_t size = strlennull(szItem) + 2;
- LPSTR aItem = (LPSTR)_alloca(size);
-
- if (utf8_decode_static(szItem, aItem, (int)size))
- item = SendMessageA(ctrl, msg, 0, (LPARAM)aItem);
- }
+ LPWSTR wItem = make_unicode_string(szItem);
+ item = SendMessageW(ctrl, msg, 0, (LPARAM)wItem);
+ SAFE_FREE(wItem);
return item;
}