diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/core/stdchat/src/chat.h | 1 | ||||
-rw-r--r-- | src/core/stdchat/src/window.cpp | 4 | ||||
-rw-r--r-- | src/modules/clist/clc.cpp | 2 | ||||
-rw-r--r-- | src/modules/clist/clui.cpp | 4 | ||||
-rw-r--r-- | src/modules/findadd/findadd.cpp | 2 | ||||
-rw-r--r-- | src/modules/protocols/protoopts.cpp | 4 | ||||
-rw-r--r-- | src/modules/skin/hotkey_opts.cpp | 2 |
7 files changed, 9 insertions, 10 deletions
diff --git a/src/core/stdchat/src/chat.h b/src/core/stdchat/src/chat.h index 463b56061b..61ddc2bd03 100644 --- a/src/core/stdchat/src/chat.h +++ b/src/core/stdchat/src/chat.h @@ -23,6 +23,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include <shlobj.h>
#include <windows.h>
+#include <windowsx.h>
#include <commctrl.h>
#include <richedit.h>
#include <ole2.h>
diff --git a/src/core/stdchat/src/window.cpp b/src/core/stdchat/src/window.cpp index 3e486387a2..3a7969746e 100644 --- a/src/core/stdchat/src/window.cpp +++ b/src/core/stdchat/src/window.cpp @@ -1075,8 +1075,8 @@ static LRESULT CALLBACK NicklistSubclassProc(HWND hwnd, UINT msg, WPARAM wParam, case WM_CONTEXTMENU:
TVHITTESTINFO hti;
{
- hti.pt.x = (short)LOWORD(lParam);
- hti.pt.y = (short)HIWORD(lParam);
+ hti.pt.x = GET_X_LPARAM(lParam);
+ hti.pt.y = GET_Y_LPARAM(lParam);
if (hti.pt.x == -1 && hti.pt.y == -1) {
int index = SendMessage(hwnd, LB_GETCURSEL, 0, 0);
int top = SendMessage(hwnd, LB_GETTOPINDEX, 0, 0);
diff --git a/src/modules/clist/clc.cpp b/src/modules/clist/clc.cpp index 044e579b1a..6e10794f1e 100644 --- a/src/modules/clist/clc.cpp +++ b/src/modules/clist/clc.cpp @@ -1234,7 +1234,7 @@ LRESULT CALLBACK fnContactListControlWndProc(HWND hwnd, UINT msg, WPARAM wParam, if (!dat->filterSearch)
dat->szQuickSearch[0] = 0;
{
- POINT pt = { (short)LOWORD(lParam), (short)HIWORD(lParam) };
+ POINT pt = { GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam) };
if (pt.x == -1 && pt.y == -1) {
dat->selection = cli.pfnGetRowByIndex(dat, dat->selection, &contact, NULL);
if (dat->selection != -1)
diff --git a/src/modules/clist/clui.cpp b/src/modules/clist/clui.cpp index c330fdc95f..50a3b3f8d6 100644 --- a/src/modules/clist/clui.cpp +++ b/src/modules/clist/clui.cpp @@ -921,9 +921,7 @@ LRESULT CALLBACK fnContactListWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM case WM_CONTEXTMENU:
{
// x/y might be -1 if it was generated by a kb click
- POINT pt;
- pt.x = (short) LOWORD(lParam);
- pt.y = (short) HIWORD(lParam);
+ POINT pt = { GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam) };
RECT rc;
GetWindowRect(cli.hwndContactTree, &rc);
diff --git a/src/modules/findadd/findadd.cpp b/src/modules/findadd/findadd.cpp index 9ac78eee80..f031259d37 100644 --- a/src/modules/findadd/findadd.cpp +++ b/src/modules/findadd/findadd.cpp @@ -801,7 +801,7 @@ static INT_PTR CALLBACK DlgProcFindAdd(HWND hwndDlg, UINT msg, WPARAM wParam, LP case WM_CONTEXTMENU: { - POINT pt = { LOWORD(lParam), HIWORD(lParam) }; + POINT pt = { GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam) };
LVHITTESTINFO lvhti; lvhti.pt = pt; diff --git a/src/modules/protocols/protoopts.cpp b/src/modules/protocols/protoopts.cpp index 7e1c34b770..10968a73b2 100644 --- a/src/modules/protocols/protoopts.cpp +++ b/src/modules/protocols/protoopts.cpp @@ -688,10 +688,10 @@ INT_PTR CALLBACK AccMgrDlgProc(HWND hwndDlg, UINT message, WPARAM wParam, LPARAM case WM_CONTEXTMENU:
if (GetWindowLongPtr((HWND)wParam, GWL_ID) == IDC_ACCLIST) {
- POINT pt = { (signed short)LOWORD(lParam), (signed short)HIWORD(lParam) };
+ POINT pt = { GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam) };
int iItem = ListBox_GetCurSel(hwndList);
- if ((pt.x == -1) && (pt.y == -1)) {
+ if (pt.x == -1 && pt.y == -1) {
if (iItem != LB_ERR) {
RECT rc;
ListBox_GetItemRect(hwndList, iItem, &rc);
diff --git a/src/modules/skin/hotkey_opts.cpp b/src/modules/skin/hotkey_opts.cpp index 6a71702630..4c04405e09 100644 --- a/src/modules/skin/hotkey_opts.cpp +++ b/src/modules/skin/hotkey_opts.cpp @@ -664,7 +664,7 @@ static INT_PTR CALLBACK sttOptionsDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, case WM_CONTEXTMENU: if (GetWindowLongPtr((HWND)wParam, GWL_ID) == IDC_LV_HOTKEYS) { HWND hwndList = (HWND)wParam; - POINT pt = { (signed short)LOWORD(lParam), (signed short)HIWORD(lParam) }; + POINT pt = { GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam) };
LVITEM lvi = {0}; THotkeyItem *item = NULL; |