From 58973a21a30bf95427fd43c456e41e35c386218c Mon Sep 17 00:00:00 2001 From: Vadim Dashevskiy Date: Fri, 15 Jun 2012 18:52:16 +0000 Subject: another portion of "#ifsef Unicode" removal git-svn-id: http://svn.miranda-ng.org/main/trunk@434 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/Console/Console.c | 20 +++----------------- 1 file changed, 3 insertions(+), 17 deletions(-) (limited to 'plugins/Console') diff --git a/plugins/Console/Console.c b/plugins/Console/Console.c index 7692260239..f6c451b5dd 100644 --- a/plugins/Console/Console.c +++ b/plugins/Console/Console.c @@ -602,11 +602,7 @@ static INT_PTR CALLBACK LogDlgProc(HWND hwndDlg,UINT message,WPARAM wParam,LPARA pchData = (TCHAR*)GlobalLock(hClipboardData); _tcscpy(pchData, buf); GlobalUnlock(hClipboardData); - #ifdef UNICODE - SetClipboardData(CF_UNICODETEXT,hClipboardData); - #else - SetClipboardData(CF_TEXT,hClipboardData); - #endif + SetClipboardData(CF_UNICODETEXT,hClipboardData); } CloseClipboard(); } @@ -790,14 +786,11 @@ static INT_PTR CALLBACK ConsoleDlgProc(HWND hwndDlg,UINT message,WPARAM wParam,L { tci.mask = TCIF_PARAM | TCIF_TEXT; tci.lParam = (LPARAM)lw; -#ifdef _UNICODE + tci.pszText = mir_a2u(lw->Module); idx = TabCtrl_InsertItem(hTabs, tabCount, &tci); mir_free(tci.pszText); -#else - tci.pszText = lw->Module; - idx = TabCtrl_InsertItem(hTabs, tabCount, &tci); -#endif + tabCount++; } @@ -1067,7 +1060,6 @@ static int OnFastDump(WPARAM wParam,LPARAM lParam) strncpy(dumpMsg->szModule, ((NETLIBUSER*)wParam)->szDescriptiveName, sizeof(dumpMsg->szModule))[ sizeof(dumpMsg->szModule)-1 ] = 0; -#ifdef _UNICODE { wchar_t *ucs2; @@ -1083,13 +1075,7 @@ static int OnFastDump(WPARAM wParam,LPARAM lParam) wcscat( str, ucs2 ); mir_free( ucs2 ); } -#else - memcpy( str, logMsg->pszHead, headlen ); - memcpy( str + headlen, logMsg->pszMsg, msglen + 1 ); - // try to detect utf8 - mir_utf8decode( str + headlen, NULL ); -#endif InMsgs++; PostMessage(hwndConsole, HM_DUMP, 0, (LPARAM)dumpMsg); } -- cgit v1.2.3