summaryrefslogtreecommitdiff
path: root/plugins/Variables/variables.cpp
diff options
context:
space:
mode:
authorVadim Dashevskiy <watcherhd@gmail.com>2012-06-16 14:33:30 +0000
committerVadim Dashevskiy <watcherhd@gmail.com>2012-06-16 14:33:30 +0000
commit05c989e58aeffcfb59cebaca6797cb69dd25cb1e (patch)
tree460bde28df51ea7b01109b56818b5880ac47ba66 /plugins/Variables/variables.cpp
parentac7bf920f219a7aed7eb163c8b3195e66c12e4da (diff)
another portion of "#ifdef Unicode" removal
git-svn-id: http://svn.miranda-ng.org/main/trunk@446 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Variables/variables.cpp')
-rw-r--r--plugins/Variables/variables.cpp21
1 files changed, 4 insertions, 17 deletions
diff --git a/plugins/Variables/variables.cpp b/plugins/Variables/variables.cpp
index aa316b9169..69adcd87f0 100644
--- a/plugins/Variables/variables.cpp
+++ b/plugins/Variables/variables.cpp
@@ -436,7 +436,7 @@ static INT_PTR formatStringService(WPARAM wParam, LPARAM lParam) {
}
orgFormat = fi->tszFormat;
orgSource = fi->tszExtraText;
-#ifdef UNICODE
+
if (!(fi->flags&FIF_TCHAR)) {
copied = TRUE;
log_debugA("a2u (%s)", fi->szExtraText);
@@ -451,23 +451,12 @@ static INT_PTR formatStringService(WPARAM wParam, LPARAM lParam) {
tszFormat = fi->tszFormat;
tszSource = fi->tszExtraText;
}
-#else
- if (fi->flags&FIF_UNICODE) {
- if (!bWarningShown) {
- MessageBoxA(NULL, "A plugin using UNICODE encoding tries to make use of the ANSI version of Variables.\r\nPlease use the UNICODE version of Variables or the ANSI version of the plugin using Variables.", "Variables", MB_OK);
- bWarningShown = TRUE;
- }
- return (int)NULL;
- }
- copied = FALSE;
- tszFormat = fi->szFormat;
- tszSource = fi->szExtraText;
-#endif
+
fi->tszFormat = tszFormat;
fi->tszExtraText = tszSource;
tRes = formatString(fi);
-#ifdef UNICODE
+
if (!(fi->flags&FIF_TCHAR)) {
res = (int)u2a(tRes);
free(tRes);
@@ -475,9 +464,7 @@ static INT_PTR formatStringService(WPARAM wParam, LPARAM lParam) {
else {
res = (int)tRes;
}
-#else
- res = (int)tRes;
-#endif
+
if (copied) {
if (tszFormat != NULL) {
free(tszFormat);