From db75c4e194cb97aa4e352fa38a45c012ce597e30 Mon Sep 17 00:00:00 2001 From: Luboš Luňák Date: Tue, 8 Oct 2019 11:47:17 +0200 Subject: make WinSalVirtualDevice::SetSize() always call Init() for all Impl's I don't see why this should be OpenGL-only. For WinSalGraphicsImpl it's a no-op anyway, and for other Impl's it may be useful to find out that they have been in fact resized. For Skia this is necessary because Init() the first time may get called with empty size. Change-Id: I4a8fa0fc633b415735d3633e89f208ab1c1f1229 --- vcl/win/gdi/salvd.cxx | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/vcl/win/gdi/salvd.cxx b/vcl/win/gdi/salvd.cxx index 57ad9581b1c4..e1cacb8b098a 100644 --- a/vcl/win/gdi/salvd.cxx +++ b/vcl/win/gdi/salvd.cxx @@ -218,12 +218,7 @@ bool WinSalVirtualDevice::SetSize( long nDX, long nDY ) mhBmp.reset(hNewBmp); if (mpGraphics) - { - WinOpenGLSalGraphicsImpl *pImpl; - pImpl = dynamic_cast< WinOpenGLSalGraphicsImpl * >(mpGraphics->GetImpl()); - if (pImpl) - pImpl->Init(); - } + mpGraphics->GetImpl()->Init(); return true; } -- cgit v1.2.3