mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 01:55:19 +00:00
[ATL] -Add COMMAND_CODE_HANDLER macro
This commit is contained in:
parent
bf51ed17f8
commit
deb908b038
1 changed files with 9 additions and 0 deletions
|
@ -1800,6 +1800,15 @@ public:
|
|||
return TRUE; \
|
||||
}
|
||||
|
||||
#define COMMAND_CODE_HANDLER(code, func) \
|
||||
if (uMsg == WM_COMMAND && code == HIWORD(wParam)) \
|
||||
{ \
|
||||
bHandled = TRUE; \
|
||||
lResult = func(HIWORD(wParam), LOWORD(wParam), (HWND)lParam, bHandled); \
|
||||
if (bHandled) \
|
||||
return TRUE; \
|
||||
}
|
||||
|
||||
#define COMMAND_RANGE_HANDLER(idFirst, idLast, func) \
|
||||
if (uMsg == WM_COMMAND && LOWORD(wParam) >= idFirst && LOWORD(wParam) <= idLast) \
|
||||
{ \
|
||||
|
|
Loading…
Reference in a new issue