Kaydet (Commit) d892e5d4 authored tarafından Chris Sherlock's avatar Chris Sherlock Kaydeden (comit) Caolán McNamara

fdo#74424 Use Window::GetOutDev() to access ImplGetGraphics()

Part of the decoupling of Window from OutputDevice. We now get
the Window's OutputDevice instance and manipulate this. Do not rely
on the inherited function.

Conflicts:
	vcl/source/window/window2.cxx

Change-Id: I964596bb6457ccb24e69bad15c497dbf97e5880f
Reviewed-on: https://gerrit.libreoffice.org/7789Reviewed-by: 's avatarCaolán McNamara <caolanm@redhat.com>
Tested-by: 's avatarCaolán McNamara <caolanm@redhat.com>
üst e45c729d
......@@ -937,7 +937,8 @@ void Window::ImplInit( Window* pParent, WinBits nStyle, SystemParentData* pSyste
}
else
{
if ( ImplGetGraphics() )
OutputDevice *pOutDev = GetOutDev();
if ( pOutDev->ImplGetGraphics() )
{
mpGraphics->GetResolution( mpWindowImpl->mpFrameData->mnDPIX, mpWindowImpl->mpFrameData->mnDPIY );
}
......@@ -1396,9 +1397,14 @@ ImplWinData* Window::ImplGetWinData() const
SalGraphics* Window::ImplGetFrameGraphics() const
{
if ( mpWindowImpl->mpFrameWindow->mpGraphics )
{
mpWindowImpl->mpFrameWindow->mbInitClipRegion = true;
}
else
mpWindowImpl->mpFrameWindow->ImplGetGraphics();
{
OutputDevice *pFrameWinOutDev = mpWindowImpl->mpFrameWindow;
pFrameWinOutDev->ImplGetGraphics();
}
mpWindowImpl->mpFrameWindow->mpGraphics->ResetClipRegion();
return mpWindowImpl->mpFrameWindow->mpGraphics;
}
......
......@@ -424,7 +424,7 @@ void Window::Invert( const Polygon& rPoly, sal_uInt16 nFlags )
// we need a graphics
if ( !mpGraphics )
{
if ( !ImplGetGraphics() )
if ( !pOutDev->ImplGetGraphics() )
return;
}
......@@ -505,7 +505,7 @@ void Window::InvertTracking( const Rectangle& rRect, sal_uInt16 nFlags )
// we need a graphics
if ( !mpGraphics )
{
if ( !ImplGetGraphics() )
if ( !pOutDev->ImplGetGraphics() )
return;
}
......
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