https://git.reactos.org/?p=reactos.git;a=commitdiff;h=f9b89c9961fa89d4d3891…
commit f9b89c9961fa89d4d3891be9f61af0933e0bead0
Author: Katayama Hirofumi MZ <katayama.hirofumi.mz(a)gmail.com>
AuthorDate: Thu Mar 18 18:41:03 2021 +0900
Commit: Katayama Hirofumi MZ <katayama.hirofumi.mz(a)gmail.com>
CommitDate: Thu Mar 18 18:41:03 2021 +0900
[SDK][INCLUDE] msgdump.h: Support RegisterWindowMessage
msgdump.h: Version 18.
---
sdk/include/reactos/msgdump.h | 33 ++++++++++++++++++++++++---------
1 file changed, 24 insertions(+), 9 deletions(-)
diff --git a/sdk/include/reactos/msgdump.h b/sdk/include/reactos/msgdump.h
index eeea6a2cae8..1076c7e8943 100644
--- a/sdk/include/reactos/msgdump.h
+++ b/sdk/include/reactos/msgdump.h
@@ -2,10 +2,10 @@
* PROJECT: ReactOS header files
* LICENSE: CC-BY-4.0 (
https://spdx.org/licenses/CC-BY-4.0.html)
* PURPOSE: Win32API message dumping
- * COPYRIGHT: Copyright 2018-2019 Katayama Hirofumi MZ
(katayama.hirofumi.mz(a)gmail.com)
+ * COPYRIGHT: Copyright 2018-2021 Katayama Hirofumi MZ
(katayama.hirofumi.mz(a)gmail.com)
*/
#ifndef _INC_MSGDUMP
-#define _INC_MSGDUMP 17 /* Version 17 */
+#define _INC_MSGDUMP 18 /* Version 18 */
/*
* NOTE: MD_msgdump function in this file provides Win32API message dump feature.
@@ -4654,7 +4654,7 @@ MD_RichEdit_OnGetTextMode(HWND hwnd)
static __inline LRESULT MSGDUMP_API
MD_msgdump(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
- TCHAR szClass[24], sz[2];
+ TCHAR szClass[24], sz[2], szMsg[64];
szClass[0] = 0;
GetClassName(hwnd, szClass, ARRAYSIZE(szClass));
sz[0] = szClass[0];
@@ -5341,15 +5341,24 @@ MD_msgdump(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
#endif
default:
{
- if (WM_USER <= uMsg && uMsg <= 0x7FFF)
+ if (WM_USER <= uMsg && uMsg < WM_APP)
{
return MD_OnUser(hwnd, uMsg, wParam, lParam);
}
- if (WM_APP <= uMsg && uMsg <= 0xBFFF)
+ if (WM_APP <= uMsg && uMsg < MAXINTATOM)
{
return MD_OnApp(hwnd, uMsg, wParam, lParam);
}
- return MD_OnUnknown(hwnd, uMsg, wParam, lParam);
+ else if (MAXINTATOM <= uMsg && uMsg <= MAXWORD &&
+ GetClipboardFormatName(uMsg, szMsg, _countof(szMsg)))
+ {
+ MSGDUMP_TPRINTF(TEXT("%sWM_%u[\"%s\"](hwnd:%p, wParam:%p,
lParam:%p)\n"),
+ MSGDUMP_PREFIX, uMsg, szMsg, (void *)hwnd, wParam,
lParam);
+ }
+ else
+ {
+ return MD_OnUnknown(hwnd, uMsg, wParam, lParam);
+ }
}
}
return 0;
@@ -5360,7 +5369,7 @@ MD_msgresult(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam,
LRESULT lResult
{
#define DEFINE_RESULT(WM_) case WM_: MSGDUMP_TPRINTF(TEXT("%s") TEXT(#WM_)
TEXT(": hwnd:%p, lResult:%p\n"), \
MSGDUMP_PREFIX, (void *)hwnd,
lResult); break
- TCHAR szClass[24], sz[2];
+ TCHAR szClass[24], sz[2], szMsg[64];
szClass[0] = 0;
GetClassName(hwnd, szClass, ARRAYSIZE(szClass));
sz[0] = szClass[0];
@@ -6060,16 +6069,22 @@ MD_msgresult(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam,
LRESULT lResult
DEFINE_RESULT(WM_GETTITLEBARINFOEX);
#endif
default:
- if (WM_USER <= uMsg && uMsg <= 0x7FFF)
+ if (WM_USER <= uMsg && uMsg < WM_APP)
{
MSGDUMP_TPRINTF(TEXT("%sWM_USER+%u(hwnd:%p, lResult:%p)\n"),
MSGDUMP_PREFIX, uMsg - WM_USER, (void *)hwnd, (void
*)lResult);
}
- else if (WM_APP <= uMsg && uMsg <= 0xBFFF)
+ else if (WM_APP <= uMsg && uMsg < MAXINTATOM)
{
MSGDUMP_TPRINTF(TEXT("%sWM_APP+%u(hwnd:%p, lResult:%p)\n"),
MSGDUMP_PREFIX, uMsg - WM_APP, (void *)hwnd, (void
*)lResult);
}
+ else if (MAXINTATOM <= uMsg && uMsg <= MAXWORD &&
+ GetClipboardFormatName(uMsg, szMsg, _countof(szMsg)))
+ {
+ MSGDUMP_TPRINTF(TEXT("%sWM_%u[\"%s\"](hwnd:%p,
lResult:%p)\n"),
+ MSGDUMP_PREFIX, uMsg, szMsg, (void *)hwnd, (void *)lResult);
+ }
else
{
MSGDUMP_TPRINTF(TEXT("%sWM_%u(hwnd:%p, lResult:%p)\n"),