win32: force double buffer in the designer. Issue #33687

git-svn-id: trunk@57820 -
This commit is contained in:
ondrej 2018-05-07 19:15:30 +00:00
parent 216dd81ec1
commit dce6efa577

View File

@ -601,7 +601,10 @@ begin
PushEraseBkgndCommand(ecDiscard);
// check if double buffering is requested
useDoubleBuffer := (ControlDC = 0) and TWSWinControlClass(TWinControl(lWinControl).WidgetSetClass).GetDoubleBuffered(lWinControl);
useDoubleBuffer := (ControlDC = 0) and (
((csDesigning in lWinControl.ComponentState) and (GetSystemMetrics(SM_REMOTESESSION)=0)) // force double buffer in the designer
or TWSWinControlClass(TWinControl(lWinControl).WidgetSetClass).GetDoubleBuffered(lWinControl));
if useDoubleBuffer then
BufferWasSaved := PrepareDoubleBuffer(DoubleBufferBitmapOld)
else