summaryrefslogtreecommitdiff
path: root/plugins/YAPP
diff options
context:
space:
mode:
authorVadim Dashevskiy <watcherhd@gmail.com>2012-06-16 14:51:46 +0000
committerVadim Dashevskiy <watcherhd@gmail.com>2012-06-16 14:51:46 +0000
commit8617d7e00546f892c9084f7c382648b23d8bbb63 (patch)
tree2be51254236644b678418c1147f223a30e030bda /plugins/YAPP
parent05c989e58aeffcfb59cebaca6797cb69dd25cb1e (diff)
another portion of "#ifdef Unicode" removal
git-svn-id: http://svn.miranda-ng.org/main/trunk@447 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/YAPP')
-rw-r--r--plugins/YAPP/common.h8
-rw-r--r--plugins/YAPP/popup_history_dlg.cpp13
-rw-r--r--plugins/YAPP/popups2.cpp8
-rw-r--r--plugins/YAPP/popwin.cpp6
4 files changed, 11 insertions, 24 deletions
diff --git a/plugins/YAPP/common.h b/plugins/YAPP/common.h
index 8b11eca6f0..51d5b1cd41 100644
--- a/plugins/YAPP/common.h
+++ b/plugins/YAPP/common.h
@@ -25,9 +25,6 @@
#define _WIN32_IE 0x0600 // Change this to the appropriate value to target other versions of IE.
#endif
-#if defined( UNICODE ) && !defined( _UNICODE )
-#define _UNICODE
-#endif
#include <m_stdhdr.h>
@@ -108,11 +105,8 @@ typedef struct {
} PopupData;
#define PDF_UNICODE 0x0001
-#ifdef _UNICODE
+
#define PDF_TCHAR PDF_UNICODE
-#else
-#define PDF_TCHAR 0
-#endif
// windowProc messages
#define PM_INIT (WM_USER + 0x0202) // message sent to your windowProc after the window has been initialized
diff --git a/plugins/YAPP/popup_history_dlg.cpp b/plugins/YAPP/popup_history_dlg.cpp
index fda95893d9..e192139c8a 100644
--- a/plugins/YAPP/popup_history_dlg.cpp
+++ b/plugins/YAPP/popup_history_dlg.cpp
@@ -336,14 +336,11 @@ IEVIEWEVENTDATA *CreateAndFillEventData(PopupHistoryData *popupItem)
{
eventData->cbSize = sizeof(IEVIEWEVENTDATA);
eventData->iType = IEED_EVENT_MESSAGE;
-#ifdef UNICODE
+
eventData->dwFlags = IEEDF_UNICODE_NICK | IEEDF_UNICODE_TEXT | IEEDF_UNICODE_TEXT2;
eventData->pszNickW = popupItem->titleT;
eventData->pszTextW = popupItem->messageT;
-#else
- eventData->pszNick = popupItem->titleT;
- eventData->pszText = popupItem->messageT;
-#endif
+
eventData->time = (DWORD) popupItem->timestamp;
eventData->next = NULL;
}
@@ -479,11 +476,9 @@ void CopyPopupDataToClipboard(HWND hList, int selection)
int found = 0;
int count = ListView_GetItemCount(hList);
int textType;
-#ifdef _UNICODE
+
textType = CF_UNICODETEXT;
-#else
- textType = CF_TEXT;
-#endif
+
for (i = 0; i < count; i++)
{
diff --git a/plugins/YAPP/popups2.cpp b/plugins/YAPP/popups2.cpp
index 9ebee50070..c90196336f 100644
--- a/plugins/YAPP/popups2.cpp
+++ b/plugins/YAPP/popups2.cpp
@@ -69,7 +69,7 @@ extern "C" __declspec(dllexport) const MUUID* MirandaPluginInterfaces(void)
int ReloadFont(WPARAM wParam, LPARAM lParam)
{
-#ifdef _UNICODE
+
if(ServiceExists(MS_FONT_GETW)) {
LOGFONTW log_font;
if(hFontFirstLine) DeleteObject(hFontFirstLine);
@@ -87,7 +87,7 @@ int ReloadFont(WPARAM wParam, LPARAM lParam)
colSidebar = CallService(MS_COLOUR_GETW, (WPARAM)&colour_id_sidebarw, 0);
colTitleUnderline = CallService(MS_COLOUR_GETW, (WPARAM)&colour_id_titleunderlinew, 0);
} else
-#endif
+
{
LOGFONTA log_font;
if(hFontFirstLine) DeleteObject(hFontFirstLine);
@@ -148,7 +148,7 @@ int ModulesLoaded(WPARAM wParam, LPARAM lParam) {
CallService(MS_UPDATE_REGISTER, 0, (WPARAM)&update);
}
-#ifdef _UNICODE
+
if(ServiceExists(MS_FONT_REGISTERW))
{
font_id_firstlinew.cbSize = sizeof(FontIDW);
@@ -221,7 +221,7 @@ int ModulesLoaded(WPARAM wParam, LPARAM lParam) {
hEventReloadFont = HookEvent(ME_FONT_RELOAD, ReloadFont);
}
else
-#endif
+
if(ServiceExists(MS_FONT_REGISTER))
{
font_id_firstline.cbSize = sizeof(FontID);
diff --git a/plugins/YAPP/popwin.cpp b/plugins/YAPP/popwin.cpp
index 789464d94c..585f8f34bf 100644
--- a/plugins/YAPP/popwin.cpp
+++ b/plugins/YAPP/popwin.cpp
@@ -767,11 +767,9 @@ void InitWindowStack() {
MySetLayeredWindowAttributes = (BOOL (WINAPI *)(HWND,COLORREF,BYTE,DWORD))GetProcAddress(hUserDll, "SetLayeredWindowAttributes");
MyAnimateWindow=(BOOL (WINAPI*)(HWND,DWORD,DWORD))GetProcAddress(hUserDll,"AnimateWindow");
MyMonitorFromRect=(HMONITOR (WINAPI*)(LPCRECT,DWORD))GetProcAddress(hUserDll, "MonitorFromRect");
- #if defined( _UNICODE )
+
MyGetMonitorInfo=(BOOL (WINAPI*)(HMONITOR,LPMONITORINFO))GetProcAddress(hUserDll, "GetMonitorInfoW");
- #else
- MyGetMonitorInfo=(BOOL (WINAPI*)(HMONITOR,LPMONITORINFO))GetProcAddress(hUserDll, "GetMonitorInfoA");
- #endif
+
}
}