I have problem with WinAPI radio buttons. Basically I have three of them and when I switch from one to another the old one is still checked until I hover mouse over it or I click again the button I clicked before. I tried with invalidating both - controls and the whole window - with no luck. I have similar issue with checkboxes in the same dialog - I must hover over them to see their actual state.
EDIT:
This is done when each button is selected (note 1011 ... 1013 are radio buttons IDs):
RECT rect;
BringWindowToTop(GetDlgItem(hwnd, 1011));
GetClientRect(GetDlgItem(hwnd, 1011), &rect);
InvalidateRect(GetDlgItem(hwnd, 1011), &rect, TRUE);
RedrawWindow(GetDlgItem(hwnd, 1011), &rect, NULL, RDW_INVALIDATE | RDW_UPDATENOW | RDW_ERASE);
BringWindowToTop(GetDlgItem(hwnd, 1012));
GetClientRect(GetDlgItem(hwnd, 1012), &rect);
InvalidateRect(GetDlgItem(hwnd, 1012), &rect, TRUE);
RedrawWindow(GetDlgItem(hwnd, 1012), &rect, NULL, RDW_INVALIDATE | RDW_UPDATENOW | RDW_ERASE);
BringWindowToTop(GetDlgItem(hwnd, 1013));
GetClientRect(GetDlgItem(hwnd, 1013), &rect);
InvalidateRect(GetDlgItem(hwnd, 1013), &rect, TRUE);
RedrawWindow(GetDlgItem(hwnd, 1013), &rect, NULL, RDW_INVALIDATE | RDW_UPDATENOW | RDW_ERASE);
I also tried sending WM_PAINT message and call UpdateWindow() on both - whole window and each radio button - no effect.