Commit 936c6c4e authored by Guy L. Albertelli's avatar Guy L. Albertelli Committed by Alexandre Julliard

Added wParam and lParam as parameters in SPY_ExitMessage

Added dump for the STYLECHANG[ING|ED] messages. Dump structures on exit only if message allows changes.
parent d67dacea
......@@ -26,7 +26,7 @@ extern const char *SPY_GetMsgName( UINT msg );
extern void SPY_EnterMessage( INT iFlag, HWND hwnd, UINT msg,
WPARAM wParam, LPARAM lParam );
extern void SPY_ExitMessage( INT iFlag, HWND hwnd, UINT msg,
LRESULT lReturn );
LRESULT lReturn, WPARAM wParam, LPARAM lParam );
extern int SPY_Init(void);
#endif /* __WINE_SPY_H */
......@@ -618,7 +618,7 @@ LRESULT WINAPI DefWindowProc16( HWND16 hwnd, UINT16 msg, WPARAM16 wParam,
}
WIN_ReleaseWndPtr(wndPtr);
SPY_ExitMessage( SPY_RESULT_DEFWND16, hwnd, msg, result );
SPY_ExitMessage( SPY_RESULT_DEFWND16, hwnd, msg, result, wParam, lParam );
return result;
}
......@@ -682,7 +682,7 @@ LRESULT WINAPI DefWindowProcA( HWND hwnd, UINT msg, WPARAM wParam,
}
WIN_ReleaseWndPtr(wndPtr);
SPY_ExitMessage( SPY_RESULT_DEFWND, hwnd, msg, result );
SPY_ExitMessage( SPY_RESULT_DEFWND, hwnd, msg, result, wParam, lParam );
return result;
}
......@@ -737,6 +737,6 @@ LRESULT WINAPI DefWindowProcW(
break;
}
WIN_ReleaseWndPtr(wndPtr);
SPY_ExitMessage( SPY_RESULT_DEFWND, hwnd, msg, result );
SPY_ExitMessage( SPY_RESULT_DEFWND, hwnd, msg, result, wParam, lParam );
return result;
}
......@@ -1803,9 +1803,9 @@ static LRESULT MSG_SendMessage( HWND hwnd, UINT msg, WPARAM wParam,
}
if (flags & SMSG_WIN32)
SPY_ExitMessage( SPY_RESULT_OK, hwnd, msg, *pRes );
SPY_ExitMessage( SPY_RESULT_OK, hwnd, msg, *pRes, wParam, lParam );
else
SPY_ExitMessage( SPY_RESULT_OK16, hwnd, msg, *pRes );
SPY_ExitMessage( SPY_RESULT_OK16, hwnd, msg, *pRes, wParam, lParam );
END:
WIN_ReleaseWndPtr(wndPtr);
return ret;
......@@ -2309,7 +2309,8 @@ LONG WINAPI DispatchMessage16( const MSG16* msg )
retval = CallWindowProc16( (WNDPROC16)wndPtr->winproc,
msg->hwnd, msg->message,
msg->wParam, msg->lParam );
SPY_ExitMessage( SPY_RESULT_OK16, msg->hwnd, msg->message, retval );
SPY_ExitMessage( SPY_RESULT_OK16, msg->hwnd, msg->message, retval,
msg->wParam, msg->lParam );
WIN_ReleaseWndPtr(wndPtr);
wndPtr = WIN_FindWndPtr(msg->hwnd);
......@@ -2393,7 +2394,8 @@ LONG WINAPI DispatchMessageA( const MSG* msg )
retval = CallWindowProcA( (WNDPROC)wndPtr->winproc,
msg->hwnd, msg->message,
msg->wParam, msg->lParam );
SPY_ExitMessage( SPY_RESULT_OK, msg->hwnd, msg->message, retval );
SPY_ExitMessage( SPY_RESULT_OK, msg->hwnd, msg->message, retval,
msg->wParam, msg->lParam );
WIN_ReleaseWndPtr(wndPtr);
wndPtr = WIN_FindWndPtr(msg->hwnd);
......@@ -2475,7 +2477,8 @@ LONG WINAPI DispatchMessageW( const MSG* msg )
retval = CallWindowProcW( (WNDPROC)wndPtr->winproc,
msg->hwnd, msg->message,
msg->wParam, msg->lParam );
SPY_ExitMessage( SPY_RESULT_OK, msg->hwnd, msg->message, retval );
SPY_ExitMessage( SPY_RESULT_OK, msg->hwnd, msg->message, retval,
msg->wParam, msg->lParam );
WIN_ReleaseWndPtr(wndPtr);
wndPtr = WIN_FindWndPtr(msg->hwnd);
......
......@@ -838,11 +838,12 @@ const char *SPY_GetWndName( HWND hwnd )
/***********************************************************************
* SPY_DumpStructure
*/
void SPY_DumpStructure (UINT msg, LPARAM structure)
void SPY_DumpStructure (UINT msg, BOOL enter, LPARAM structure)
{
switch (msg)
{
case WM_DRAWITEM:
if (!enter) break;
{ DRAWITEMSTRUCT *lpdis = (DRAWITEMSTRUCT*) structure;
TRACE("DRAWITEMSTRUCT: CtlType=0x%08x CtlID=0x%08x\n", lpdis->CtlType, lpdis->CtlID);
TRACE("itemID=0x%08x itemAction=0x%08x itemState=0x%08x\n", lpdis->itemID, lpdis->itemAction, lpdis->itemState);
......@@ -857,7 +858,16 @@ void SPY_DumpStructure (UINT msg, LPARAM structure)
TRACE("itemData=0x%08lx\n", lpmis->itemData);
}
break;
case WM_STYLECHANGED:
if (!enter) break;
case WM_STYLECHANGING:
{ LPSTYLESTRUCT ss = (LPSTYLESTRUCT) structure;
TRACE("STYLESTRUCT: StyleOld=0x%08lx, StyleNew=0x%08lx\n",
ss->styleOld, ss->styleNew);
}
break;
case WM_NOTIFY:
if (!enter) break;
{ NMHDR * pnmh = (NMHDR*) structure;
TRACE("NMHDR hwndFrom=0x%08x idFrom=0x%08x code=0x%08x\n", pnmh->hwndFrom, pnmh->idFrom, pnmh->code);
}
......@@ -916,7 +926,7 @@ void SPY_EnterMessage( INT iFlag, HWND hWnd, UINT msg,
{ TRACE("%*s(%08x) %-16s message [%04x] %s sent from %s wp=%08x lp=%08lx\n",
SPY_IndentLevel, "", hWnd, pname, msg, SPY_GetMsgName( msg ),
taskName, wParam, lParam );
SPY_DumpStructure(msg, lParam);
SPY_DumpStructure(msg, TRUE, lParam);
}
}
break;
......@@ -942,7 +952,8 @@ void SPY_EnterMessage( INT iFlag, HWND hWnd, UINT msg,
/***********************************************************************
* SPY_ExitMessage
*/
void SPY_ExitMessage( INT iFlag, HWND hWnd, UINT msg, LRESULT lReturn )
void SPY_ExitMessage( INT iFlag, HWND hWnd, UINT msg, LRESULT lReturn,
WPARAM wParam, LPARAM lParam )
{
LPCSTR pname;
......@@ -976,6 +987,7 @@ void SPY_ExitMessage( INT iFlag, HWND hWnd, UINT msg, LRESULT lReturn )
TRACE(" %*s(%08x) %-16s message [%04x] %s returned %08lx\n",
SPY_IndentLevel, "", hWnd, pname, msg,
SPY_GetMsgName( msg ), lReturn );
SPY_DumpStructure(msg, FALSE, lParam);
break;
case SPY_RESULT_INVALIDHWND16:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment