diff options
author | George Hazan <george.hazan@gmail.com> | 2016-09-05 11:04:46 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2016-09-05 11:04:46 +0000 |
commit | 18ee7073d76f02c5c78182c3aeee7427b469bd01 (patch) | |
tree | 21c5b90169da0ed79d82d5dc07b5c888177b9260 /src | |
parent | b6432457c35f22d5fd4377284e2e7d5d6736e6dc (diff) |
Menu_DrawItem & Menu_MeasureItem now simply receive LPARAM
git-svn-id: http://svn.miranda-ng.org/main/trunk@17255 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'src')
-rw-r--r-- | src/core/stdchat/src/window.cpp | 8 | ||||
-rw-r--r-- | src/core/stdfile/src/filerecvdlg.cpp | 4 | ||||
-rw-r--r-- | src/core/stdfile/src/filesenddlg.cpp | 4 | ||||
-rw-r--r-- | src/core/stdfile/src/filexferdlg.cpp | 4 | ||||
-rw-r--r-- | src/core/stdmsg/src/msgdialog.cpp | 4 | ||||
-rw-r--r-- | src/mir_app/src/clc.cpp | 4 | ||||
-rw-r--r-- | src/mir_app/src/clui.cpp | 4 | ||||
-rw-r--r-- | src/mir_app/src/menu_utils.cpp | 6 |
8 files changed, 20 insertions, 18 deletions
diff --git a/src/core/stdchat/src/window.cpp b/src/core/stdchat/src/window.cpp index c9525b7723..642dd5b2ea 100644 --- a/src/core/stdchat/src/window.cpp +++ b/src/core/stdchat/src/window.cpp @@ -1058,7 +1058,7 @@ static LRESULT CALLBACK NicklistSubclassProc(HWND hwnd, UINT msg, WPARAM wParam, {
MEASUREITEMSTRUCT *mis = (MEASUREITEMSTRUCT *)lParam;
if (mis->CtlType == ODT_MENU)
- return Menu_MeasureItem((LPMEASUREITEMSTRUCT)lParam);
+ return Menu_MeasureItem(lParam);
}
return FALSE;
@@ -1066,7 +1066,7 @@ static LRESULT CALLBACK NicklistSubclassProc(HWND hwnd, UINT msg, WPARAM wParam, {
DRAWITEMSTRUCT *dis = (DRAWITEMSTRUCT *)lParam;
if (dis->CtlType == ODT_MENU)
- return Menu_DrawItem((LPDRAWITEMSTRUCT)lParam);
+ return Menu_DrawItem(lParam);
}
return FALSE;
@@ -1808,7 +1808,7 @@ INT_PTR CALLBACK RoomWndProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lPar {
MEASUREITEMSTRUCT *mis = (MEASUREITEMSTRUCT *)lParam;
if (mis->CtlType == ODT_MENU)
- return Menu_MeasureItem((LPMEASUREITEMSTRUCT)lParam);
+ return Menu_MeasureItem(lParam);
int ih = GetTextPixelSize(L"AQGgl'", g_Settings.UserListFont, FALSE);
int ih2 = GetTextPixelSize(L"AQGg'", g_Settings.UserListHeadingsFont, FALSE);
@@ -1827,7 +1827,7 @@ INT_PTR CALLBACK RoomWndProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lPar {
DRAWITEMSTRUCT *dis = (DRAWITEMSTRUCT *)lParam;
if (dis->CtlType == ODT_MENU)
- return Menu_DrawItem((LPDRAWITEMSTRUCT)lParam);
+ return Menu_DrawItem(lParam);
if (dis->CtlID == IDC_LIST) {
int index = dis->itemID;
diff --git a/src/core/stdfile/src/filerecvdlg.cpp b/src/core/stdfile/src/filerecvdlg.cpp index 1d155b1544..2d38df4c64 100644 --- a/src/core/stdfile/src/filerecvdlg.cpp +++ b/src/core/stdfile/src/filerecvdlg.cpp @@ -267,7 +267,7 @@ INT_PTR CALLBACK DlgProcRecvFile(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l return TRUE;
case WM_MEASUREITEM:
- return Menu_MeasureItem((LPMEASUREITEMSTRUCT)lParam);
+ return Menu_MeasureItem(lParam);
case WM_DRAWITEM:
{
@@ -283,7 +283,7 @@ INT_PTR CALLBACK DlgProcRecvFile(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l }
}
}
- return Menu_DrawItem((LPDRAWITEMSTRUCT)lParam);
+ return Menu_DrawItem(lParam);
case WM_COMMAND:
if (Clist_MenuProcessCommand(LOWORD(wParam), MPCF_CONTACTMENU, dat->hContact))
diff --git a/src/core/stdfile/src/filesenddlg.cpp b/src/core/stdfile/src/filesenddlg.cpp index ccfc68af3f..c2551426a4 100644 --- a/src/core/stdfile/src/filesenddlg.cpp +++ b/src/core/stdfile/src/filesenddlg.cpp @@ -250,7 +250,7 @@ INT_PTR CALLBACK DlgProcSendFile(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l return TRUE;
case WM_MEASUREITEM:
- return Menu_MeasureItem((LPMEASUREITEMSTRUCT)lParam);
+ return Menu_MeasureItem(lParam);
case WM_DRAWITEM:
{
@@ -266,7 +266,7 @@ INT_PTR CALLBACK DlgProcSendFile(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l }
}
}
- return Menu_DrawItem((LPDRAWITEMSTRUCT)lParam);
+ return Menu_DrawItem(lParam);
case M_FILECHOOSEDONE:
if (lParam != 0) {
diff --git a/src/core/stdfile/src/filexferdlg.cpp b/src/core/stdfile/src/filexferdlg.cpp index cfb958c689..603a0c5cd8 100644 --- a/src/core/stdfile/src/filexferdlg.cpp +++ b/src/core/stdfile/src/filexferdlg.cpp @@ -328,10 +328,10 @@ INT_PTR CALLBACK DlgProcFileTransfer(HWND hwndDlg, UINT msg, WPARAM wParam, LPAR break; case WM_MEASUREITEM: - return Menu_MeasureItem((LPMEASUREITEMSTRUCT)lParam); + return Menu_MeasureItem(lParam); case WM_DRAWITEM: - return Menu_DrawItem((LPDRAWITEMSTRUCT)lParam); + return Menu_DrawItem(lParam); case WM_FT_CLEANUP: if (!dat->fs) { diff --git a/src/core/stdmsg/src/msgdialog.cpp b/src/core/stdmsg/src/msgdialog.cpp index 2286d0c5a1..e5309b928b 100644 --- a/src/core/stdmsg/src/msgdialog.cpp +++ b/src/core/stdmsg/src/msgdialog.cpp @@ -1278,7 +1278,7 @@ INT_PTR CALLBACK DlgProcMessage(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM l {
LPMEASUREITEMSTRUCT mis = (LPMEASUREITEMSTRUCT)lParam;
if (mis->CtlType == ODT_MENU)
- return Menu_MeasureItem((LPMEASUREITEMSTRUCT)lParam);
+ return Menu_MeasureItem(lParam);
}
break;
@@ -1286,7 +1286,7 @@ INT_PTR CALLBACK DlgProcMessage(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM l {
LPDRAWITEMSTRUCT dis = (LPDRAWITEMSTRUCT)lParam;
if (dis->CtlType == ODT_MENU)
- return Menu_DrawItem((LPDRAWITEMSTRUCT)lParam);
+ return Menu_DrawItem(lParam);
if (dis->hwndItem == dat->hwndStatus) {
DrawStatusIcons(dat->hContact, dis->hDC, dis->rcItem, 2);
return TRUE;
diff --git a/src/mir_app/src/clc.cpp b/src/mir_app/src/clc.cpp index 872a099390..aa01ae56bb 100644 --- a/src/mir_app/src/clc.cpp +++ b/src/mir_app/src/clc.cpp @@ -1225,10 +1225,10 @@ LRESULT CALLBACK fnContactListControlWndProc(HWND hwnd, UINT uMsg, WPARAM wParam return 0;
case WM_MEASUREITEM:
- return Menu_MeasureItem((LPMEASUREITEMSTRUCT)lParam);
+ return Menu_MeasureItem(lParam);
case WM_DRAWITEM:
- return Menu_DrawItem((LPDRAWITEMSTRUCT)lParam);
+ return Menu_DrawItem(lParam);
case WM_COMMAND:
hit = cli.pfnGetRowByIndex(dat, dat->selection, &contact, NULL);
diff --git a/src/mir_app/src/clui.cpp b/src/mir_app/src/clui.cpp index 6c474e04cd..a182ab0f66 100644 --- a/src/mir_app/src/clui.cpp +++ b/src/mir_app/src/clui.cpp @@ -947,7 +947,7 @@ LRESULT CALLBACK fnContactListWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM ((LPMEASUREITEMSTRUCT)lParam)->itemHeight = 0;
return TRUE;
}
- return Menu_MeasureItem((LPMEASUREITEMSTRUCT)lParam);
+ return Menu_MeasureItem(lParam);
case WM_DRAWITEM:
{
@@ -1006,7 +1006,7 @@ LRESULT CALLBACK fnContactListWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM IcoLib_ReleaseIcon(hIcon);
return TRUE;
}
- return Menu_DrawItem((LPDRAWITEMSTRUCT)lParam);
+ return Menu_DrawItem(lParam);
}
}
return 0;
diff --git a/src/mir_app/src/menu_utils.cpp b/src/mir_app/src/menu_utils.cpp index b301b8cac0..30a2a02eec 100644 --- a/src/mir_app/src/menu_utils.cpp +++ b/src/mir_app/src/menu_utils.cpp @@ -107,11 +107,12 @@ TMO_IntMenuItem* MO_RecursiveWalkMenu(TMO_IntMenuItem *parent, pfnWalkFunc func, ///////////////////////////////////////////////////////////////////////////////
-MIR_APP_DLL(BOOL) Menu_MeasureItem(MEASUREITEMSTRUCT *mis)
+MIR_APP_DLL(BOOL) Menu_MeasureItem(LPARAM lParam)
{
if (!bIsGenMenuInited)
return FALSE;
+ MEASUREITEMSTRUCT *mis = (MEASUREITEMSTRUCT*)lParam;
if (mis == NULL)
return FALSE;
@@ -133,11 +134,12 @@ MIR_APP_DLL(BOOL) Menu_MeasureItem(MEASUREITEMSTRUCT *mis) ///////////////////////////////////////////////////////////////////////////////
-MIR_APP_DLL(BOOL) Menu_DrawItem(DRAWITEMSTRUCT *dis)
+MIR_APP_DLL(BOOL) Menu_DrawItem(LPARAM lParam)
{
if (!bIsGenMenuInited)
return FALSE;
+ DRAWITEMSTRUCT *dis = (DRAWITEMSTRUCT*)lParam;
if (dis == NULL)
return FALSE;
|