On December 11, 2003 04:32 pm, Andrew de Quincey wrote:
I have concluded that the WM_ERASEBKGND is sent from within WM_PAINT when the toolbar detects that the mouse has moved off a button and wants to de-highlight it.
Well, it probably does a InvalidateRect() call. You can try an ugly InvaldateRect(hwnd, 0, TRUE); but this will probably result in flicker. For added bonus, figure out the button's rect, and pass it in:
/* figure out stuff in rect */ InvalidateRect(hwnd, &rect, TRUE);
BTW, what are the parameters of WM_ERASEBKGND?