diff options
author | George Hazan <george.hazan@gmail.com> | 2014-02-11 19:01:03 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2014-02-11 19:01:03 +0000 |
commit | 1925d3521846f4e6683d3d537cc41de9c9bd7250 (patch) | |
tree | 3f9bd6e5f557dc9eac040b078ededd5ee8e7870d /plugins/TabSRMM/src/msgs.cpp | |
parent | b63d67c92da0c420ee7c4f81b8ecdd3b8cfd132d (diff) |
"we don't need these variables" (c) Pink Floyd
git-svn-id: http://svn.miranda-ng.org/main/trunk@8101 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/TabSRMM/src/msgs.cpp')
-rw-r--r-- | plugins/TabSRMM/src/msgs.cpp | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/plugins/TabSRMM/src/msgs.cpp b/plugins/TabSRMM/src/msgs.cpp index a64a8661b4..98dde21f3b 100644 --- a/plugins/TabSRMM/src/msgs.cpp +++ b/plugins/TabSRMM/src/msgs.cpp @@ -294,9 +294,8 @@ static INT_PTR ReadMessageCommand(WPARAM, LPARAM lParam) * for filling the message input box with a passed message
*/
-INT_PTR SendMessageCommand_W(WPARAM wParam, LPARAM lParam)
+INT_PTR SendMessageCommand_W(WPARAM hContact, LPARAM lParam)
{
- MCONTACT hContact = wParam;
TNewWindowData newData = { 0 };
int isSplit = 1;
@@ -309,9 +308,9 @@ INT_PTR SendMessageCommand_W(WPARAM wParam, LPARAM lParam) wchar_t *tszText = (wchar_t *)mir_alloc((iLen + 1) * sizeof(wchar_t));
wcsncpy(tszText, (wchar_t *)lParam, iLen + 1);
tszText[iLen] = 0;
- PostMessage(PluginConfig.g_hwndHotkeyHandler, DM_SENDMESSAGECOMMANDW, wParam, (LPARAM)tszText);
- } else
- PostMessage(PluginConfig.g_hwndHotkeyHandler, DM_SENDMESSAGECOMMANDW, wParam, 0);
+ PostMessage(PluginConfig.g_hwndHotkeyHandler, DM_SENDMESSAGECOMMANDW, hContact, (LPARAM)tszText);
+ }
+ else PostMessage(PluginConfig.g_hwndHotkeyHandler, DM_SENDMESSAGECOMMANDW, hContact, 0);
return 0;
}
@@ -353,9 +352,8 @@ INT_PTR SendMessageCommand_W(WPARAM wParam, LPARAM lParam) * contacts handle must be passed in wParam.
*/
-INT_PTR SendMessageCommand(WPARAM wParam, LPARAM lParam)
+INT_PTR SendMessageCommand(WPARAM hContact, LPARAM lParam)
{
- MCONTACT hContact = wParam;
TNewWindowData newData = { 0 };
int isSplit = 1;
@@ -365,9 +363,9 @@ INT_PTR SendMessageCommand(WPARAM wParam, LPARAM lParam) char *szText = (char *)mir_alloc(iLen + 1);
strncpy(szText, (char *)lParam, iLen + 1);
szText[iLen] = 0;
- PostMessage(PluginConfig.g_hwndHotkeyHandler, DM_SENDMESSAGECOMMAND, wParam, (LPARAM)szText);
+ PostMessage(PluginConfig.g_hwndHotkeyHandler, DM_SENDMESSAGECOMMAND, hContact, (LPARAM)szText);
} else
- PostMessage(PluginConfig.g_hwndHotkeyHandler, DM_SENDMESSAGECOMMAND, wParam, 0);
+ PostMessage(PluginConfig.g_hwndHotkeyHandler, DM_SENDMESSAGECOMMAND, hContact, 0);
return 0;
}
@@ -389,9 +387,10 @@ INT_PTR SendMessageCommand(WPARAM wParam, LPARAM lParam) SendMessageA(hEdit, EM_REPLACESEL, FALSE, (LPARAM)(char *) lParam);
}
SendMessage(hwnd, DM_ACTIVATEME, 0, 0); // ask the message window about its parent...
- } else {
+ }
+ else {
TCHAR szName[CONTAINER_NAMELEN + 1];
- GetContainerNameForContact(wParam, szName, CONTAINER_NAMELEN);
+ GetContainerNameForContact(hContact, szName, CONTAINER_NAMELEN);
TContainerData *pContainer = FindContainerByName(szName);
if (pContainer == NULL)
pContainer = CreateContainer(szName, FALSE, hContact);
|