print window handle in message outout
This commit is contained in:
parent
046bdb1716
commit
676fdb03f3
|
@ -1,3 +1,9 @@
|
||||||
|
2005-02-12 Alexander Gottwald <ago at freedesktop dot org>
|
||||||
|
|
||||||
|
* winmsg.h:
|
||||||
|
* winmsg.c:
|
||||||
|
print window handle in message outout
|
||||||
|
|
||||||
2005-02-08 Alexander Gottwald <ago at freedesktop dot org>
|
2005-02-08 Alexander Gottwald <ago at freedesktop dot org>
|
||||||
|
|
||||||
* winkeybd.c:
|
* winkeybd.c:
|
||||||
|
|
|
@ -147,12 +147,14 @@ winW32ErrorEx(int verb, const char *msg, DWORD errorcode)
|
||||||
#if CYGDEBUG
|
#if CYGDEBUG
|
||||||
void winDebugWin32Message(const char* function, HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
|
void winDebugWin32Message(const char* function, HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
|
||||||
{
|
{
|
||||||
|
static int force = 0;
|
||||||
|
|
||||||
if (message >= WM_USER)
|
if (message >= WM_USER)
|
||||||
{
|
{
|
||||||
if (getenv("WIN_DEBUG_MESSAGES") || getenv("WIN_DEBUG_WM_USER"))
|
if (force || getenv("WIN_DEBUG_MESSAGES") || getenv("WIN_DEBUG_WM_USER"))
|
||||||
{
|
{
|
||||||
winDebug("%s - Message WM_USER + %d", function, message - WM_USER);
|
winDebug("%s - Message WM_USER + %d\n", function, message - WM_USER);
|
||||||
winDebug("\twParam 0x%x lParam 0x%x\n", wParam, lParam);
|
winDebug("\thwnd 0x%x wParam 0x%x lParam 0x%x\n", hwnd, wParam, lParam);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (message < MESSAGE_NAMES_LEN && MESSAGE_NAMES[message])
|
else if (message < MESSAGE_NAMES_LEN && MESSAGE_NAMES[message])
|
||||||
|
@ -161,10 +163,10 @@ void winDebugWin32Message(const char* function, HWND hwnd, UINT message, WPARAM
|
||||||
char buffer[64];
|
char buffer[64];
|
||||||
snprintf(buffer, sizeof(buffer), "WIN_DEBUG_%s", msgname);
|
snprintf(buffer, sizeof(buffer), "WIN_DEBUG_%s", msgname);
|
||||||
buffer[63] = 0;
|
buffer[63] = 0;
|
||||||
if (getenv("WIN_DEBUG_MESSAGES") || getenv(buffer))
|
if (force || getenv("WIN_DEBUG_MESSAGES") || getenv(buffer))
|
||||||
{
|
{
|
||||||
winDebug("%s - Message %s", function, MESSAGE_NAMES[message]);
|
winDebug("%s - Message %s\n", function, MESSAGE_NAMES[message]);
|
||||||
winDebug("\twParam 0x%x lParam 0x%x\n", wParam, lParam);
|
winDebug("\thwnd 0x%x wParam 0x%x lParam 0x%x\n", hwnd, wParam, lParam);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue