mirror of
https://github.com/reactos/reactos.git
synced 2025-01-05 13:59:25 +00:00
[COMCTL32] -Implement sending the BCN_HOTITEMCHANGE notification.
svn path=/trunk/; revision=74150
This commit is contained in:
parent
301c476074
commit
2ae045e8a1
1 changed files with 18 additions and 0 deletions
|
@ -515,8 +515,17 @@ LRESULT WINAPI ButtonWndProc_common(HWND hWnd, UINT uMsg,
|
|||
state = get_button_state( hWnd );
|
||||
if (state & BST_HOT)
|
||||
{
|
||||
NMBCHOTITEM nmhotitem;
|
||||
|
||||
state &= ~BST_HOT;
|
||||
set_button_state(hWnd, state);
|
||||
|
||||
nmhotitem.hdr.hwndFrom = hWnd;
|
||||
nmhotitem.hdr.idFrom = GetWindowLongPtrW (hWnd, GWLP_ID);
|
||||
nmhotitem.hdr.code = BCN_HOTITEMCHANGE;
|
||||
nmhotitem.dwFlags = HICF_LEAVING;
|
||||
SendMessageW(GetParent(hWnd), WM_NOTIFY, nmhotitem.hdr.idFrom, (LPARAM)&nmhotitem);
|
||||
|
||||
InvalidateRect(hWnd, NULL, TRUE);
|
||||
}
|
||||
break;
|
||||
|
@ -527,8 +536,17 @@ LRESULT WINAPI ButtonWndProc_common(HWND hWnd, UINT uMsg,
|
|||
state = get_button_state( hWnd );
|
||||
if ((state & BST_HOT) == 0)
|
||||
{
|
||||
NMBCHOTITEM nmhotitem;
|
||||
|
||||
state |= BST_HOT;
|
||||
set_button_state(hWnd, state);
|
||||
|
||||
nmhotitem.hdr.hwndFrom = hWnd;
|
||||
nmhotitem.hdr.idFrom = GetWindowLongPtrW (hWnd, GWLP_ID);
|
||||
nmhotitem.hdr.code = BCN_HOTITEMCHANGE;
|
||||
nmhotitem.dwFlags = HICF_ENTERING;
|
||||
SendMessageW(GetParent(hWnd), WM_NOTIFY, nmhotitem.hdr.idFrom, (LPARAM)&nmhotitem);
|
||||
|
||||
InvalidateRect(hWnd, NULL, TRUE);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue