[COMCTL32] Revert "button: Don't erase the area of the checkbox or the text."

This reverts commit 0.4.12-dev-347-g
75a80ec823
by explcit request of Giannis Adamopoulos.

I double-checked and confirm, that
this revert fixes both regressions CORE-15595 & CORE-15696.
On the downside the revert will intensify again the regression CORE-13278
(will make the text flash again as well).

Giannis Adamopoulos mentioned earlier, that using double-buffering
eventually could be a valid way out of CORE-13278 instead.
This commit is contained in:
Joachim Henze 2019-01-29 19:25:57 +01:00
parent 232cf9f0b6
commit 1e05f9cc32

View file

@ -1550,9 +1550,7 @@ static void CB_Paint( const BUTTON_INFO *infoPtr, HDC hDC, UINT action )
/* Since WM_ERASEBKGND does nothing, first prepare background */
if (action == ODA_SELECT) FillRect( hDC, &rbox, hBrush );
#ifndef __REACTOS__
if (action == ODA_DRAWENTIRE) FillRect( hDC, &client, hBrush );
#endif
/* Draw label */
client = rtext;
@ -1618,15 +1616,6 @@ static void CB_Paint( const BUTTON_INFO *infoPtr, HDC hDC, UINT action )
if (action == ODA_DRAWENTIRE)
BUTTON_DrawLabel(infoPtr, hDC, dtFlags, &rtext);
#ifdef __REACTOS__
if (action == ODA_DRAWENTIRE)
{
ExcludeClipRect(hDC, rbox.left, rbox.top, rbox.right, rbox.bottom);
ExcludeClipRect(hDC, rtext.left, rtext.top + 1, rtext.right, rtext.bottom - 1);
FillRect( hDC, &client, hBrush );
}
#endif
/* ... and focus */
if (action == ODA_FOCUS || (state & BST_FOCUS))
{