Commit 88ea4c52 authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

comctl32/trackbar: Update thumb immediately on key press.

parent dd294410
......@@ -672,7 +672,14 @@ static void test_position(void)
r = SendMessageA(hWndTrackbar, TBM_GETPOS, 0, 0);
ok(r == 30, "got %d\n", r);
SendMessageA(hWndTrackbar, TBM_GETTHUMBRECT, 0, (LPARAM)&rect2);
ok(rect.left != rect2.left, "got %d\n", rect.left);
ok(rect.left != rect2.left, "got %d, expected %d\n", rect2.left, rect.left);
/* now move it with keys */
SendMessageA(hWndTrackbar, WM_KEYDOWN, VK_END, 0);
r = SendMessageA(hWndTrackbar, TBM_GETPOS, 0, 0);
ok(r == 100, "got %d\n", r);
SendMessageA(hWndTrackbar, TBM_GETTHUMBRECT, 0, (LPARAM)&rect);
ok(rect.left != rect2.left, "got %d, expected %d\n", rect.left, rect2.left);
DestroyWindow(hWndTrackbar);
}
......
......@@ -1821,7 +1821,7 @@ TRACKBAR_KeyDown (TRACKBAR_INFO *infoPtr, INT nVirtKey)
}
if (pos != infoPtr->lPos) {
infoPtr->flags |=TB_THUMBPOSCHANGED;
TRACKBAR_UpdateThumb (infoPtr);
TRACKBAR_InvalidateThumbMove (infoPtr, pos, infoPtr->lPos);
}
......
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