Kaydet (Commit) 25ade745 authored tarafından Miklos Vajna's avatar Miklos Vajna

SdrPaintWindow: no own buffer for rendercontext-enabled vcl::Windows

The buffered overlay manager paints using a timer, which is problematic
if the given vcl::Window already supports double-buffering itself, so
always use direct (to the rendercontext) painting in that case.

Change-Id: I93144c02814fd511f333224ab058374c7da369f0
üst 7df3879d
......@@ -201,8 +201,9 @@ void SdrPaintWindow::impCreateOverlayManager()
// is it a window?
if(OUTDEV_WINDOW == GetOutputDevice().GetOutDevType())
{
vcl::Window* pWindow = dynamic_cast<vcl::Window*>(&GetOutputDevice());
// decide which OverlayManager to use
if(GetPaintView().IsBufferedOverlayAllowed() && mbUseBuffer)
if(GetPaintView().IsBufferedOverlayAllowed() && mbUseBuffer && !pWindow->SupportsDoubleBuffering())
{
// buffered OverlayManager, buffers its background and refreshes from there
// for pure overlay changes (no system redraw). The 3rd parameter specifies
......@@ -225,7 +226,6 @@ void SdrPaintWindow::impCreateOverlayManager()
// Request a repaint so that the buffered overlay manager fills
// its buffer properly. This is a workaround for missing buffer
// updates.
vcl::Window* pWindow = dynamic_cast<vcl::Window*>(&GetOutputDevice());
if (pWindow != NULL)
pWindow->Invalidate();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment