IDA (yes, that again :), doesn't redraw its toolbar buttons properly. When you move the mouse over them, its meant to have a button rollover. Under wine however, it highlights the button, but does not de-highlight. Some investigation shows that these toolbar windows have the TBSTYLE_FLAT style. Some more investigation (with spyxx) showed that under windows, each toolbar receives a WM_PAINT message, and, when the mouse leaves a button (and it should be de-highlighted), it receives a single WM_ERASEBKGND message. 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. Lemme know what you think.. any suggestions greatly appreciated.
Index: dlls/comctl32/toolbar.c =================================================================== RCS file: /home/wine/wine/dlls/comctl32/toolbar.c,v retrieving revision 1.147 diff -u -r1.147 toolbar.c --- dlls/comctl32/toolbar.c 26 Nov 2003 22:05:02 -0000 1.147 +++ dlls/comctl32/toolbar.c 11 Dec 2003 21:26:04 -0000 @@ -1019,6 +1019,7 @@ RECT rcTemp, rcClient; NMTBCUSTOMDRAW tbcd; DWORD ntfret; + DWORD dwStyle = GetWindowLongA (hwnd, GWL_STYLE); /* if imagelist belongs to the app, it can be changed by the app after setting it */ @@ -1030,6 +1031,11 @@ } TOOLBAR_DumpToolbar (infoPtr, __LINE__); + + /* Investigation with spyxx shows that TBSTYLE_FLAT toolbars + send a single erasebkgnd message before drawing */ + if (dwStyle & TBSTYLE_FLAT) + SendMessageA(hwnd, WM_ERASEBKGND, (DWORD) hdc, 0); /* Send initial notify */ ZeroMemory (&tbcd, sizeof(NMTBCUSTOMDRAW));