summaryrefslogtreecommitdiff
path: root/sd/source
diff options
context:
space:
mode:
Diffstat (limited to 'sd/source')
-rw-r--r--sd/source/ui/accessibility/AccessibleDocumentViewBase.cxx2
-rw-r--r--sd/source/ui/accessibility/AccessibleViewForwarder.cxx3
-rw-r--r--sd/source/ui/animations/motionpathtag.cxx4
-rw-r--r--sd/source/ui/annotations/annotationtag.cxx5
-rw-r--r--sd/source/ui/dlg/animobjs.cxx2
-rw-r--r--sd/source/ui/func/fuconbez.cxx4
-rw-r--r--sd/source/ui/func/fudraw.cxx6
-rw-r--r--sd/source/ui/func/fuediglu.cxx10
-rw-r--r--sd/source/ui/func/fusnapln.cxx2
-rw-r--r--sd/source/ui/func/futext.cxx4
-rw-r--r--sd/source/ui/slideshow/showwin.cxx34
-rw-r--r--sd/source/ui/slideshow/slideshow.cxx2
-rw-r--r--sd/source/ui/slideshow/slideshowimpl.cxx8
-rw-r--r--sd/source/ui/slidesorter/controller/SlideSorterController.cxx6
-rw-r--r--sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx8
-rw-r--r--sd/source/ui/slidesorter/view/SlideSorterView.cxx4
-rw-r--r--sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx2
-rw-r--r--sd/source/ui/slidesorter/view/SlsInsertionIndicatorOverlay.cxx2
-rw-r--r--sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx8
-rw-r--r--sd/source/ui/slidesorter/view/SlsPageObjectLayouter.cxx2
-rw-r--r--sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx2
-rw-r--r--sd/source/ui/unoidl/DrawController.cxx4
-rw-r--r--sd/source/ui/view/WindowUpdater.cxx4
-rw-r--r--sd/source/ui/view/drviews1.cxx2
-rw-r--r--sd/source/ui/view/drviews2.cxx2
-rw-r--r--sd/source/ui/view/drviews3.cxx2
-rw-r--r--sd/source/ui/view/drviews4.cxx4
-rw-r--r--sd/source/ui/view/drviews5.cxx12
-rw-r--r--sd/source/ui/view/drviewsa.cxx2
-rw-r--r--sd/source/ui/view/drviewsf.cxx2
-rw-r--r--sd/source/ui/view/drviewsh.cxx4
-rw-r--r--sd/source/ui/view/outlview.cxx4
-rw-r--r--sd/source/ui/view/sdview.cxx3
-rw-r--r--sd/source/ui/view/sdview4.cxx2
-rw-r--r--sd/source/ui/view/sdwindow.cxx6
-rw-r--r--sd/source/ui/view/viewoverlaymanager.cxx2
-rw-r--r--sd/source/ui/view/viewshe2.cxx16
-rw-r--r--sd/source/ui/view/viewshel.cxx4
38 files changed, 98 insertions, 97 deletions
diff --git a/sd/source/ui/accessibility/AccessibleDocumentViewBase.cxx b/sd/source/ui/accessibility/AccessibleDocumentViewBase.cxx
index 8436e88f9bc5..ef1d1240c315 100644
--- a/sd/source/ui/accessibility/AccessibleDocumentViewBase.cxx
+++ b/sd/source/ui/accessibility/AccessibleDocumentViewBase.cxx
@@ -69,7 +69,7 @@ AccessibleDocumentViewBase::AccessibleDocumentViewBase (
mxController (rxController),
maViewForwarder (
static_cast<SdrPaintView*>(pViewShell->GetView()),
- *pSdWindow)
+ *pSdWindow->GetOutDev())
{
if (mxController.is())
mxModel = mxController->getModel();
diff --git a/sd/source/ui/accessibility/AccessibleViewForwarder.cxx b/sd/source/ui/accessibility/AccessibleViewForwarder.cxx
index cc0900a836de..9cebb322f006 100644
--- a/sd/source/ui/accessibility/AccessibleViewForwarder.cxx
+++ b/sd/source/ui/accessibility/AccessibleViewForwarder.cxx
@@ -79,8 +79,7 @@ Point AccessibleViewForwarder::LogicToPixel(const Point& rPoint) const
{
SdrPaintWindow* pPaintWindow = mpView->GetPaintWindow(static_cast<sal_uInt32>(mnWindowId));
OutputDevice& rOutDev = pPaintWindow->GetOutputDevice();
- ::tools::Rectangle aBBox(
- static_cast<vcl::Window&>(rOutDev).GetWindowExtentsRelative(nullptr));
+ ::tools::Rectangle aBBox(rOutDev.GetOwnerWindow()->GetWindowExtentsRelative(nullptr));
return rOutDev.LogicToPixel(rPoint) + aBBox.TopLeft();
}
else
diff --git a/sd/source/ui/animations/motionpathtag.cxx b/sd/source/ui/animations/motionpathtag.cxx
index dab0e22cf251..cf683aafd74d 100644
--- a/sd/source/ui/animations/motionpathtag.cxx
+++ b/sd/source/ui/animations/motionpathtag.cxx
@@ -445,7 +445,7 @@ bool MotionPathTag::MouseButtonDown( const MouseEvent& rMEvt, SmartHdl& rHdl )
}
else if( rMEvt.IsLeft() )
{
- OutputDevice* pOut = mrView.GetViewShell()->GetActiveWindow();
+ OutputDevice* pOut = mrView.GetViewShell()->GetActiveWindow()->GetOutDev();
Point aMDPos( pOut->PixelToLogic( rMEvt.GetPosPixel() ) );
if( !mrView.IsFrameDragSingles() && mrView.IsInsObjPointMode() && (rHdl.GetObjHdlNum() == SMART_TAG_HDL_NUM) )
@@ -686,7 +686,7 @@ bool MotionPathTag::OnMove( const KeyEvent& rKEvt )
if(rKEvt.GetKeyCode().IsMod2())
{
- OutputDevice* pOut = mrView.GetViewShell()->GetActiveWindow();
+ OutputDevice* pOut = mrView.GetViewShell()->GetActiveWindow()->GetOutDev();
Size aLogicSizeOnePixel = pOut ? pOut->PixelToLogic(Size(1,1)) : Size(100, 100);
nX *= aLogicSizeOnePixel.Width();
nY *= aLogicSizeOnePixel.Height();
diff --git a/sd/source/ui/annotations/annotationtag.cxx b/sd/source/ui/annotations/annotationtag.cxx
index 052245ac15fd..cfd632dcc2bd 100644
--- a/sd/source/ui/annotations/annotationtag.cxx
+++ b/sd/source/ui/annotations/annotationtag.cxx
@@ -414,7 +414,7 @@ bool AnnotationTag::OnMove( const KeyEvent& rKEvt )
if(rKEvt.GetKeyCode().IsMod2())
{
- OutputDevice* pOut = mrView.GetViewShell()->GetActiveWindow();
+ OutputDevice* pOut = mrView.GetViewShell()->GetActiveWindow()->GetOutDev();
Size aLogicSizeOnePixel = pOut ? pOut->PixelToLogic(Size(1,1)) : Size(100, 100);
nX *= aLogicSizeOnePixel.Width();
nY *= aLogicSizeOnePixel.Height();
@@ -574,7 +574,8 @@ void AnnotationTag::OpenPopup( bool bEdit )
if( !mpAnnotationWindow )
{
- vcl::Window* pWindow = dynamic_cast< vcl::Window* >( getView().GetFirstOutputDevice() );
+ OutputDevice* pOut = getView().GetFirstOutputDevice();
+ vcl::Window* pWindow = pOut ? pOut->GetOwnerWindow() : nullptr;
if( pWindow )
{
RealPoint2D aPosition( mxAnnotation->getPosition() );
diff --git a/sd/source/ui/dlg/animobjs.cxx b/sd/source/ui/dlg/animobjs.cxx
index 1ef08386396b..2ab345103a52 100644
--- a/sd/source/ui/dlg/animobjs.cxx
+++ b/sd/source/ui/dlg/animobjs.cxx
@@ -864,7 +864,7 @@ void AnimationWindow::AddObj (::sd::View& rView )
void AnimationWindow::CreateAnimObj (::sd::View& rView )
{
- vcl::Window* pOutWin = static_cast< vcl::Window*>(rView.GetFirstOutputDevice()); // GetWin( 0 );
+ vcl::Window* pOutWin = rView.GetFirstOutputDevice()->GetOwnerWindow(); // GetWin( 0 );
DBG_ASSERT( pOutWin, "Window does not exist!" );
// find window center
diff --git a/sd/source/ui/func/fuconbez.cxx b/sd/source/ui/func/fuconbez.cxx
index f88c0d6bf463..e9eb1b2bacef 100644
--- a/sd/source/ui/func/fuconbez.cxx
+++ b/sd/source/ui/func/fuconbez.cxx
@@ -172,7 +172,7 @@ bool FuConstructBezierPolygon::MouseButtonDown(const MouseEvent& rMEvt)
}
else
{
- mpView->MouseButtonDown(rMEvt, mpWindow);
+ mpView->MouseButtonDown(rMEvt, mpWindow->GetOutDev());
SdrObject* pObj = mpView->GetCreateObj();
@@ -204,7 +204,7 @@ bool FuConstructBezierPolygon::MouseButtonUp(const MouseEvent& rMEvt )
}
else
{
- mpView->MouseButtonUp(rMEvt, mpWindow);
+ mpView->MouseButtonUp(rMEvt, mpWindow->GetOutDev());
}
if (aVEvt.eEvent == SdrEventKind::EndCreate)
diff --git a/sd/source/ui/func/fudraw.cxx b/sd/source/ui/func/fudraw.cxx
index 2156624f4508..18cd90fb77e6 100644
--- a/sd/source/ui/func/fudraw.cxx
+++ b/sd/source/ui/func/fudraw.cxx
@@ -193,7 +193,7 @@ bool FuDraw::MouseButtonDown(const MouseEvent& rMEvt)
// look only for HelpLines when they are visible (!)
bool bHelpLine(false);
if(mpView->IsHlplVisible())
- bHelpLine = mpView->PickHelpLine(aMDPos, nHitLog, *mpWindow, nHelpLine, pPV);
+ bHelpLine = mpView->PickHelpLine(aMDPos, nHitLog, *mpWindow->GetOutDev(), nHelpLine, pPV);
bool bHitHdl = (mpView->PickHandle(aMDPos) != nullptr);
if ( bHelpLine
@@ -257,7 +257,7 @@ bool FuDraw::MouseMove(const MouseEvent& rMEvt)
mpView->MovDragHelpLine(aPos);
}
- bool bReturn = mpView->MouseMove(rMEvt, mpWindow);
+ bool bReturn = mpView->MouseMove(rMEvt, mpWindow->GetOutDev());
if (mpView->IsAction())
{
@@ -571,7 +571,7 @@ void FuDraw::ForcePointer(const MouseEvent* pMEvt)
if (bDefPointer)
{
mpWindow->SetPointer(mpView->GetPreferredPointer(
- aPnt, mpWindow, nModifier, bLeftDown));
+ aPnt, mpWindow->GetOutDev(), nModifier, bLeftDown));
}
}
diff --git a/sd/source/ui/func/fuediglu.cxx b/sd/source/ui/func/fuediglu.cxx
index efbf255f3ef2..25f4b9cf4b66 100644
--- a/sd/source/ui/func/fuediglu.cxx
+++ b/sd/source/ui/func/fuediglu.cxx
@@ -74,7 +74,7 @@ FuEditGluePoints::~FuEditGluePoints()
bool FuEditGluePoints::MouseButtonDown(const MouseEvent& rMEvt)
{
- mpView->SetActualWin( mpWindow );
+ mpView->SetActualWin( mpWindow->GetOutDev() );
bool bReturn = FuDraw::MouseButtonDown(rMEvt);
@@ -196,7 +196,7 @@ bool FuEditGluePoints::MouseButtonDown(const MouseEvent& rMEvt)
bool FuEditGluePoints::MouseMove(const MouseEvent& rMEvt)
{
- mpView->SetActualWin( mpWindow );
+ mpView->SetActualWin( mpWindow->GetOutDev() );
FuDraw::MouseMove(rMEvt);
@@ -215,7 +215,7 @@ bool FuEditGluePoints::MouseMove(const MouseEvent& rMEvt)
bool FuEditGluePoints::MouseButtonUp(const MouseEvent& rMEvt)
{
- mpView->SetActualWin( mpWindow );
+ mpView->SetActualWin( mpWindow->GetOutDev() );
bool bReturn = false;
@@ -255,7 +255,7 @@ bool FuEditGluePoints::MouseButtonUp(const MouseEvent& rMEvt)
*/
bool FuEditGluePoints::KeyInput(const KeyEvent& rKEvt)
{
- mpView->SetActualWin( mpWindow );
+ mpView->SetActualWin( mpWindow->GetOutDev() );
//Add Shift+UP/DOWN/LEFT/RIGHT key to move the position of insert point,
//and SHIFT+ENTER key to decide the position and draw the new insert point
@@ -362,7 +362,7 @@ void FuEditGluePoints::ForcePointer(const MouseEvent* pMEvt)
bool FuEditGluePoints::Command(const CommandEvent& rCEvt)
{
- mpView->SetActualWin( mpWindow );
+ mpView->SetActualWin( mpWindow->GetOutDev() );
return FuPoor::Command( rCEvt );
}
diff --git a/sd/source/ui/func/fusnapln.cxx b/sd/source/ui/func/fusnapln.cxx
index 9913f9635181..b4e93d7b41e1 100644
--- a/sd/source/ui/func/fusnapln.cxx
+++ b/sd/source/ui/func/fusnapln.cxx
@@ -84,7 +84,7 @@ void FuSnapLine::DoExecute( SfxRequest& rReq )
{
aLinePos = mpWindow->PixelToLogic(aLinePos);
sal_uInt16 nHitLog = static_cast<sal_uInt16>(mpWindow->PixelToLogic(Size(HITPIX,0)).Width());
- bLineExist = mpView->PickHelpLine(aLinePos, nHitLog, *mpWindow, nHelpLine, pPV);
+ bLineExist = mpView->PickHelpLine(aLinePos, nHitLog, *mpWindow->GetOutDev(), nHelpLine, pPV);
if ( bLineExist )
aLinePos = (pPV->GetHelpLines())[nHelpLine].GetPos();
else
diff --git a/sd/source/ui/func/futext.cxx b/sd/source/ui/func/futext.cxx
index 11e97a3bc7ed..ec04594d3d95 100644
--- a/sd/source/ui/func/futext.cxx
+++ b/sd/source/ui/func/futext.cxx
@@ -278,7 +278,7 @@ bool FuText::MouseButtonDown(const MouseEvent& rMEvt)
if (eHit == SdrHitKind::TextEdit)
{
// hit text -> SdrView handles event
- if (mpView->MouseButtonDown(rMEvt, mpWindow))
+ if (mpView->MouseButtonDown(rMEvt, mpWindow->GetOutDev()))
return true;
}
@@ -626,7 +626,7 @@ bool FuText::MouseButtonUp(const MouseEvent& rMEvt)
Point aPnt( mpWindow->PixelToLogic( rMEvt.GetPosPixel() ) );
- if( (mpView && mpView->MouseButtonUp(rMEvt, mpWindow)) || rMEvt.GetClicks() == 2 )
+ if( (mpView && mpView->MouseButtonUp(rMEvt, mpWindow->GetOutDev())) || rMEvt.GetClicks() == 2 )
return true; // handle event from SdrView
bool bEmptyTextObj = false;
diff --git a/sd/source/ui/slideshow/showwin.cxx b/sd/source/ui/slideshow/showwin.cxx
index c142dcba0945..52597482b5dd 100644
--- a/sd/source/ui/slideshow/showwin.cxx
+++ b/sd/source/ui/slideshow/showwin.cxx
@@ -56,7 +56,7 @@ ShowWindow::ShowWindow( const ::rtl::Reference< SlideshowImpl >& xController, vc
, mnFirstMouseMove(0)
, mxController( xController )
{
- SetOutDevViewType( OutDevViewType::SlideShow );
+ GetOutDev()->SetOutDevViewType( OutDevViewType::SlideShow );
// Do never mirror the preview window. This explicitly includes right
// to left writing environments.
@@ -271,7 +271,7 @@ void ShowWindow::Paint(vcl::RenderContext& /*rRenderContext*/, const ::tools::Re
}
else
{
- DrawWallpaper( rRect, maShowBackground );
+ GetOutDev()->DrawWallpaper( rRect, maShowBackground );
if( SHOWWINDOWMODE_END == meShowWindowMode )
{
@@ -385,7 +385,7 @@ void ShowWindow::TerminateShow()
maLogo.Clear();
maPauseTimer.Stop();
maMouseTimer.Stop();
- Erase();
+ GetOutDev()->Erase();
maShowBackground = Wallpaper( COL_BLACK );
meShowWindowMode = SHOWWINDOWMODE_NORMAL;
mnPauseTimeout = SLIDE_NO_TIMEOUT;
@@ -417,7 +417,7 @@ void ShowWindow::RestartShow( sal_Int32 nPageIndexToRestart )
maLogo.Clear();
maPauseTimer.Stop();
- Erase();
+ GetOutDev()->Erase();
maShowBackground = Wallpaper( COL_BLACK );
meShowWindowMode = SHOWWINDOWMODE_NORMAL;
mnPauseTimeout = SLIDE_NO_TIMEOUT;
@@ -457,9 +457,9 @@ void ShowWindow::DrawPauseScene( bool bTimeoutOnly )
{
const MapMode& rMap = GetMapMode();
const Point aOutOrg( PixelToLogic( Point() ) );
- const Size aOutSize( GetOutputSize() );
- const Size aTextSize(LogicToLogic(Size(0, 14), MapMode(MapUnit::MapPoint), rMap));
- const Size aOffset(LogicToLogic(Size(1000, 1000), MapMode(MapUnit::Map100thMM), rMap));
+ const Size aOutSize( GetOutDev()->GetOutputSize() );
+ const Size aTextSize(OutputDevice::LogicToLogic(Size(0, 14), MapMode(MapUnit::MapPoint), rMap));
+ const Size aOffset(OutputDevice::LogicToLogic(Size(1000, 1000), MapMode(MapUnit::Map100thMM), rMap));
OUString aText( SdResId( STR_PRES_PAUSE ) );
bool bDrawn = false;
@@ -478,21 +478,21 @@ void ShowWindow::DrawPauseScene( bool bTimeoutOnly )
if (maLogo.GetPrefMapMode().GetMapUnit() == MapUnit::MapPixel)
aGrfSize = PixelToLogic( maLogo.GetPrefSize() );
else
- aGrfSize = LogicToLogic( maLogo.GetPrefSize(), maLogo.GetPrefMapMode(), rMap );
+ aGrfSize = OutputDevice::LogicToLogic( maLogo.GetPrefSize(), maLogo.GetPrefMapMode(), rMap );
const Point aGrfPos( std::max( aOutOrg.X() + aOutSize.Width() - aGrfSize.Width() - aOffset.Width(), aOutOrg.X() ),
std::max( aOutOrg.Y() + aOutSize.Height() - aGrfSize.Height() - aOffset.Height(), aOutOrg.Y() ) );
if( maLogo.IsAnimated() )
- maLogo.StartAnimation( this, aGrfPos, aGrfSize, reinterpret_cast<sal_IntPtr>(this) );
+ maLogo.StartAnimation( GetOutDev(), aGrfPos, aGrfSize, reinterpret_cast<sal_IntPtr>(this) );
else
- maLogo.Draw( this, aGrfPos, aGrfSize );
+ maLogo.Draw( GetOutDev(), aGrfPos, aGrfSize );
}
if( SLIDE_NO_TIMEOUT != mnPauseTimeout )
{
MapMode aVMap( rMap );
- ScopedVclPtrInstance< VirtualDevice > pVDev( *this );
+ ScopedVclPtrInstance< VirtualDevice > pVDev( *GetOutDev() );
aVMap.SetOrigin( Point() );
pVDev->SetMapMode( aVMap );
@@ -511,7 +511,7 @@ void ShowWindow::DrawPauseScene( bool bTimeoutOnly )
aText += " ( " + aLocaleData.getDuration( ::tools::Time( 0, 0, mnPauseTimeout ) ) + " )";
pVDev->DrawText( Point( aOffset.Width(), 0 ), aText );
- DrawOutDev( Point( aOutOrg.X(), aOffset.Height() ), aVDevSize, Point(), aVDevSize, *pVDev );
+ GetOutDev()->DrawOutDev( Point( aOutOrg.X(), aOffset.Height() ), aVDevSize, Point(), aVDevSize, *pVDev );
bDrawn = true;
}
}
@@ -519,7 +519,7 @@ void ShowWindow::DrawPauseScene( bool bTimeoutOnly )
if( !bDrawn )
{
SetFont( aFont );
- DrawText( Point( aOutOrg.X() + aOffset.Width(), aOutOrg.Y() + aOffset.Height() ), aText );
+ GetOutDev()->DrawText( Point( aOutOrg.X() + aOffset.Width(), aOutOrg.Y() + aOffset.Height() ), aText );
SetFont( aOldFont );
}
}
@@ -530,7 +530,7 @@ void ShowWindow::DrawEndScene()
vcl::Font aFont( GetSettings().GetStyleSettings().GetMenuFont() );
const Point aOutOrg( PixelToLogic( Point() ) );
- const Size aTextSize(LogicToLogic(Size(0, 14), MapMode(MapUnit::MapPoint), GetMapMode()));
+ const Size aTextSize(OutputDevice::LogicToLogic(Size(0, 14), MapMode(MapUnit::MapPoint), GetMapMode()));
const OUString aText( SdResId( STR_PRES_SOFTEND ) );
aFont.SetFontSize( aTextSize );
@@ -538,7 +538,7 @@ void ShowWindow::DrawEndScene()
aFont.SetCharSet( aOldFont.GetCharSet() );
aFont.SetLanguage( aOldFont.GetLanguage() );
SetFont( aFont );
- DrawText( Point( aOutOrg.X() + aTextSize.Height(), aOutOrg.Y() + aTextSize.Height() ), aText );
+ GetOutDev()->DrawText( Point( aOutOrg.X() + aTextSize.Height(), aOutOrg.Y() + aTextSize.Height() ), aText );
SetFont( aOldFont );
}
@@ -584,7 +584,7 @@ IMPL_LINK( ShowWindow, EventHdl, VclWindowEvent&, rEvent, void )
void ShowWindow::DeleteWindowFromPaintView()
{
if( mpViewShell->GetView() )
- mpViewShell->GetView()->DeleteWindowFromPaintView( this );
+ mpViewShell->GetView()->DeleteWindowFromPaintView( GetOutDev() );
sal_uInt16 nChild = GetChildCount();
while( nChild-- )
@@ -594,7 +594,7 @@ void ShowWindow::DeleteWindowFromPaintView()
void ShowWindow::AddWindowToPaintView()
{
if( mpViewShell->GetView() )
- mpViewShell->GetView()->AddWindowToPaintView( this, nullptr );
+ mpViewShell->GetView()->AddWindowToPaintView( GetOutDev(), nullptr );
sal_uInt16 nChild = GetChildCount();
while( nChild-- )
diff --git a/sd/source/ui/slideshow/slideshow.cxx b/sd/source/ui/slideshow/slideshow.cxx
index e9917f16b467..ac63931689b5 100644
--- a/sd/source/ui/slideshow/slideshow.cxx
+++ b/sd/source/ui/slideshow/slideshow.cxx
@@ -929,7 +929,7 @@ void SlideShow::startPreview( const Reference< XDrawPage >& xDrawPage, const Ref
OutputDevice* SlideShow::getShowWindow()
{
- return mxController.is() ? mxController->mpShowWindow.get() : nullptr;
+ return mxController.is() ? mxController->mpShowWindow->GetOutDev() : nullptr;
}
int SlideShow::getAnimationMode() const
diff --git a/sd/source/ui/slideshow/slideshowimpl.cxx b/sd/source/ui/slideshow/slideshowimpl.cxx
index b52fb82a9d22..b0b8163ff57d 100644
--- a/sd/source/ui/slideshow/slideshowimpl.cxx
+++ b/sd/source/ui/slideshow/slideshowimpl.cxx
@@ -631,7 +631,7 @@ void SAL_CALL SlideshowImpl::disposing()
// take DrawView from presentation window, but give the old window back
if( mpShowWindow && mpView )
- mpView->DeleteWindowFromPaintView( mpShowWindow );
+ mpView->DeleteWindowFromPaintView( mpShowWindow->GetOutDev() );
if( mpView )
mpView->SetAnimationPause( false );
@@ -702,7 +702,7 @@ void SAL_CALL SlideshowImpl::disposing()
::tools::Rectangle aVisAreaWin = pActWin->PixelToLogic( ::tools::Rectangle( Point(0,0), aVisSizePixel) );
mpViewShell->VisAreaChanged(aVisAreaWin);
if (mpView)
- mpView->VisAreaChanged(pActWin);
+ mpView->VisAreaChanged(pActWin->GetOutDev());
pActWin->GrabFocus();
}
}
@@ -784,7 +784,7 @@ bool SlideshowImpl::startPreview(
if( mpView )
{
- mpView->AddWindowToPaintView( mpShowWindow, nullptr );
+ mpView->AddWindowToPaintView( mpShowWindow->GetOutDev(), nullptr );
mpView->SetAnimationPause( true );
}
@@ -969,7 +969,7 @@ bool SlideshowImpl::startShow( PresentationSettingsEx const * pPresSettings )
if( mpView )
{
- mpView->AddWindowToPaintView( mpShowWindow, nullptr );
+ mpView->AddWindowToPaintView( mpShowWindow->GetOutDev(), nullptr );
mpView->SetAnimationPause( true );
}
diff --git a/sd/source/ui/slidesorter/controller/SlideSorterController.cxx b/sd/source/ui/slidesorter/controller/SlideSorterController.cxx
index 6ae302375449..4dfad09947a0 100644
--- a/sd/source/ui/slidesorter/controller/SlideSorterController.cxx
+++ b/sd/source/ui/slidesorter/controller/SlideSorterController.cxx
@@ -261,7 +261,7 @@ void SlideSorterController::Paint (
try
{
- mrView.CompleteRedraw(pWindow, vcl::Region(rBBox));
+ mrView.CompleteRedraw(pWindow->GetOutDev(), vcl::Region(rBBox));
}
catch (const Exception&)
{
@@ -552,7 +552,7 @@ IMPL_LINK(SlideSorterController, WindowEventHandler, VclWindowEvent&, rEvent, vo
if (mrSlideSorter.GetViewShell() != nullptr)
mrSlideSorter.GetViewShell()->GetFrameView()->SetDrawMode(nDrawMode);
if (pActiveWindow != nullptr)
- pActiveWindow->SetDrawMode(nDrawMode);
+ pActiveWindow->GetOutDev()->SetDrawMode(nDrawMode);
mrView.HandleDrawModeChange();
// When the system font has changed a layout has to be done.
@@ -596,7 +596,7 @@ void SlideSorterController::GetCtrlState (SfxItemSet& rSet)
{
if (mrSlideSorter.GetContentWindow())
{
- DrawModeFlags nMode = mrSlideSorter.GetContentWindow()->GetDrawMode();
+ DrawModeFlags nMode = mrSlideSorter.GetContentWindow()->GetOutDev()->GetDrawMode();
sal_uInt16 nQuality = 0;
if (nMode == sd::OUTPUT_DRAWMODE_COLOR) {
diff --git a/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx b/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx
index 1780554f74e9..dfa667984a12 100644
--- a/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx
+++ b/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx
@@ -540,8 +540,8 @@ void SlideSorterViewShell::ReadFrameViewData (FrameView* pFrameView)
mpSlideSorter->GetController().Rearrange(true);
// DrawMode for 'main' window
- if (GetActiveWindow()->GetDrawMode() != pFrameView->GetDrawMode() )
- GetActiveWindow()->SetDrawMode( pFrameView->GetDrawMode() );
+ if (GetActiveWindow()->GetOutDev()->GetDrawMode() != pFrameView->GetDrawMode() )
+ GetActiveWindow()->GetOutDev()->SetDrawMode( pFrameView->GetDrawMode() );
}
// When this slide sorter is not displayed in the main window then we do
@@ -566,8 +566,8 @@ void SlideSorterViewShell::WriteFrameViewData()
mpFrameView->SetSlidesPerRow(static_cast<sal_uInt16>(rView.GetLayouter().GetColumnCount()));
// DrawMode for 'main' window
- if( mpFrameView->GetDrawMode() != GetActiveWindow()->GetDrawMode() )
- mpFrameView->SetDrawMode( GetActiveWindow()->GetDrawMode() );
+ if( mpFrameView->GetDrawMode() != GetActiveWindow()->GetOutDev()->GetDrawMode() )
+ mpFrameView->SetDrawMode( GetActiveWindow()->GetOutDev()->GetDrawMode() );
SdPage* pActualPage = GetActualPage();
if (pActualPage != nullptr)
diff --git a/sd/source/ui/slidesorter/view/SlideSorterView.cxx b/sd/source/ui/slidesorter/view/SlideSorterView.cxx
index c56bd41cff83..c1eaf8302d08 100644
--- a/sd/source/ui/slidesorter/view/SlideSorterView.cxx
+++ b/sd/source/ui/slidesorter/view/SlideSorterView.cxx
@@ -114,7 +114,7 @@ private:
SlideSorterView::SlideSorterView (SlideSorter& rSlideSorter)
: ::sd::View (
*rSlideSorter.GetModel().GetDocument(),
- rSlideSorter.GetContentWindow(),
+ rSlideSorter.GetContentWindow()->GetOutDev(),
rSlideSorter.GetViewShell()),
mrSlideSorter(rSlideSorter),
mrModel(rSlideSorter.GetModel()),
@@ -576,7 +576,7 @@ void SlideSorterView::CompleteRedraw (
if (comphelper::LibreOfficeKit::isActive())
return;
- if (pDevice == nullptr || pDevice!=mrSlideSorter.GetContentWindow())
+ if (pDevice == nullptr || pDevice!=mrSlideSorter.GetContentWindow()->GetOutDev())
return;
#ifdef DEBUG_TIMING
diff --git a/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx b/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx
index 63f89b9ca1c1..9e1eae75778a 100644
--- a/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx
+++ b/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx
@@ -424,7 +424,7 @@ void PageObjectRun::operator () (const double nGlobalTime)
// a) animations a bit more smooth and
// b) on Mac without the Flush a Reset of the page locations is not properly
// visualized when the mouse leaves the window during drag-and-drop.
- mrAnimatorAccess.GetContentWindow()->Flush();
+ mrAnimatorAccess.GetContentWindow()->GetOutDev()->Flush();
}
} // end of namespace ::sd::slidesorter::view
diff --git a/sd/source/ui/slidesorter/view/SlsInsertionIndicatorOverlay.cxx b/sd/source/ui/slidesorter/view/SlsInsertionIndicatorOverlay.cxx
index 6c17152faa9b..6b674f4f7302 100644
--- a/sd/source/ui/slidesorter/view/SlsInsertionIndicatorOverlay.cxx
+++ b/sd/source/ui/slidesorter/view/SlsInsertionIndicatorOverlay.cxx
@@ -130,7 +130,7 @@ void InsertionIndicatorOverlay::Create (
// Create virtual devices for bitmap and mask whose bitmaps later be
// combined to form the BitmapEx of the icon.
ScopedVclPtrInstance<VirtualDevice> pContent(
- *mrSlideSorter.GetContentWindow(), DeviceFormat::DEFAULT, DeviceFormat::DEFAULT);
+ *mrSlideSorter.GetContentWindow()->GetOutDev(), DeviceFormat::DEFAULT, DeviceFormat::DEFAULT);
pContent->SetOutputSizePixel(aIconSize);
pContent->SetFillColor();
diff --git a/sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx b/sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx
index 4ae4ecdeeb60..9c2ce78303c7 100644
--- a/sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx
+++ b/sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx
@@ -161,7 +161,7 @@ private:
LayeredDevice::LayeredDevice (const VclPtr<sd::Window>& pTargetWindow)
: mpTargetWindow(pTargetWindow),
mpLayers(new LayerContainer()),
- mpBackBuffer(VclPtr<VirtualDevice>::Create(*mpTargetWindow)),
+ mpBackBuffer(VclPtr<VirtualDevice>::Create(*mpTargetWindow->GetOutDev())),
maSavedMapMode(pTargetWindow->GetMapMode())
{
mpBackBuffer->SetOutputSizePixel(mpTargetWindow->GetSizePixel());
@@ -273,7 +273,7 @@ void LayeredDevice::RepaintRectangle (const ::tools::Rectangle& rRepaintRectangl
else if (mpLayers->size() == 1)
{
// Just copy the main layer into the target device.
- (*mpLayers)[0]->Repaint(*mpTargetWindow, rRepaintRectangle);
+ (*mpLayers)[0]->Repaint(*mpTargetWindow->GetOutDev(), rRepaintRectangle);
}
else
{
@@ -285,7 +285,7 @@ void LayeredDevice::RepaintRectangle (const ::tools::Rectangle& rRepaintRectangl
{
it->Repaint(*mpBackBuffer, rRepaintRectangle);
}
- DeviceCopy(*mpTargetWindow, *mpBackBuffer, rRepaintRectangle);
+ DeviceCopy(*mpTargetWindow->GetOutDev(), *mpBackBuffer, rRepaintRectangle);
}
}
@@ -387,7 +387,7 @@ void Layer::Initialize (sd::Window *pTargetWindow)
#else
if ( ! mpLayerDevice)
{
- mpLayerDevice.disposeAndReset(VclPtr<VirtualDevice>::Create(*pTargetWindow));
+ mpLayerDevice.disposeAndReset(VclPtr<VirtualDevice>::Create(*pTargetWindow->GetOutDev()));
mpLayerDevice->SetOutputSizePixel(pTargetWindow->GetSizePixel());
}
#endif
diff --git a/sd/source/ui/slidesorter/view/SlsPageObjectLayouter.cxx b/sd/source/ui/slidesorter/view/SlsPageObjectLayouter.cxx
index 6c90634e7c96..928c60306a7c 100644
--- a/sd/source/ui/slidesorter/view/SlsPageObjectLayouter.cxx
+++ b/sd/source/ui/slidesorter/view/SlsPageObjectLayouter.cxx
@@ -48,7 +48,7 @@ PageObjectLayouter::PageObjectLayouter (
maTransitionEffectBoundingBox(),
maTransitionEffectIcon(IconCache::Instance().GetIcon(BMP_FADE_EFFECT_INDICATOR)),
maCustomAnimationEffectIcon(IconCache::Instance().GetIcon(BMP_CUSTOM_ANIMATION_INDICATOR)),
- mpPageNumberFont(Theme::GetFont(Theme::Font_PageNumber, *pWindow))
+ mpPageNumberFont(Theme::GetFont(Theme::Font_PageNumber, *pWindow->GetOutDev()))
{
const Size aPageNumberAreaSize (GetPageNumberAreaSize(nPageCount));
diff --git a/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx b/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx
index be6ce4b3ef2c..7b22240abfdd 100644
--- a/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx
+++ b/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx
@@ -45,7 +45,7 @@ PageObjectPainter::PageObjectPainter (
: mrLayouter(rSlideSorter.GetView().GetLayouter()),
mpCache(rSlideSorter.GetView().GetPreviewCache()),
mpTheme(rSlideSorter.GetTheme()),
- mpPageNumberFont(Theme::GetFont(Theme::Font_PageNumber, *rSlideSorter.GetContentWindow())),
+ mpPageNumberFont(Theme::GetFont(Theme::Font_PageNumber, *rSlideSorter.GetContentWindow()->GetOutDev())),
mpShadowPainter(new FramePainter(mpTheme->GetIcon(Theme::Icon_RawShadow))),
mpFocusBorderPainter(new FramePainter(mpTheme->GetIcon(Theme::Icon_FocusBorder)))
{
diff --git a/sd/source/ui/unoidl/DrawController.cxx b/sd/source/ui/unoidl/DrawController.cxx
index fdd2e0f78378..6cf3fdb3a5a5 100644
--- a/sd/source/ui/unoidl/DrawController.cxx
+++ b/sd/source/ui/unoidl/DrawController.cxx
@@ -666,7 +666,7 @@ uno::Reference< form::runtime::XFormController > SAL_CALL DrawController::getFor
uno::Reference< form::runtime::XFormController > xController;
if ( pFormShell && pSdrView && pWindow )
- xController = FmFormShell::GetFormController( Form, *pSdrView, *pWindow );
+ xController = FmFormShell::GetFormController( Form, *pSdrView, *pWindow->GetOutDev() );
return xController;
}
@@ -703,7 +703,7 @@ uno::Reference< awt::XControl > SAL_CALL DrawController::getControl( const uno::
uno::Reference< awt::XControl > xControl;
if ( pFormShell && pSdrView && pWindow )
- pFormShell->GetFormControl( xModel, *pSdrView, *pWindow, xControl );
+ pFormShell->GetFormControl( xModel, *pSdrView, *pWindow->GetOutDev(), xControl );
return xControl;
}
diff --git a/sd/source/ui/view/WindowUpdater.cxx b/sd/source/ui/view/WindowUpdater.cxx
index 410a0470f68d..c3f1bb53e337 100644
--- a/sd/source/ui/view/WindowUpdater.cxx
+++ b/sd/source/ui/view/WindowUpdater.cxx
@@ -49,7 +49,7 @@ void WindowUpdater::RegisterWindow (vcl::Window* pWindow)
if (aWindowIterator == maWindowList.end())
{
// Update the device once right now and add it to the list.
- Update (pWindow);
+ Update (pWindow->GetOutDev());
maWindowList.emplace_back(pWindow);
}
}
@@ -115,7 +115,7 @@ void WindowUpdater::ConfigurationChanged( utl::ConfigurationBroadcaster*, Config
{
// Set the current state at all registered output devices.
for (auto& rxWindow : maWindowList)
- Update (rxWindow);
+ Update (rxWindow->GetOutDev());
// Reformat the document for the modified state to take effect.
if (mpDocument != nullptr)
diff --git a/sd/source/ui/view/drviews1.cxx b/sd/source/ui/view/drviews1.cxx
index db7cd452d860..be985ede217a 100644
--- a/sd/source/ui/view/drviews1.cxx
+++ b/sd/source/ui/view/drviews1.cxx
@@ -1169,7 +1169,7 @@ bool DrawViewShell::SwitchPage(sal_uInt16 nSelectedPage, bool bAllowChangeFocus)
Size aVisSizePixel = GetActiveWindow()->GetOutputSizePixel();
::tools::Rectangle aVisAreaWin = GetActiveWindow()->PixelToLogic( ::tools::Rectangle( Point(0,0), aVisSizePixel) );
VisAreaChanged(aVisAreaWin);
- mpDrawView->VisAreaChanged(GetActiveWindow());
+ mpDrawView->VisAreaChanged(GetActiveWindow()->GetOutDev());
// so navigator (and effect window) notice that
SfxBindings& rBindings = GetViewFrame()->GetBindings();
diff --git a/sd/source/ui/view/drviews2.cxx b/sd/source/ui/view/drviews2.cxx
index 273da605c81e..01120a842903 100644
--- a/sd/source/ui/view/drviews2.cxx
+++ b/sd/source/ui/view/drviews2.cxx
@@ -1338,7 +1338,7 @@ void DrawViewShell::FuTemporary(SfxRequest& rReq)
FuPoor::HITPIX, 0 ) ).Width());
sal_uInt16 nHelpLine;
- if( mpDrawView->PickHelpLine( aMPos, nHitLog, *GetActiveWindow(), nHelpLine, pPV) )
+ if( mpDrawView->PickHelpLine( aMPos, nHitLog, *GetActiveWindow()->GetOutDev(), nHelpLine, pPV) )
{
pPV->DeleteHelpLine( nHelpLine );
}
diff --git a/sd/source/ui/view/drviews3.cxx b/sd/source/ui/view/drviews3.cxx
index 545c7befeca4..fd5ecd53e008 100644
--- a/sd/source/ui/view/drviews3.cxx
+++ b/sd/source/ui/view/drviews3.cxx
@@ -1105,7 +1105,7 @@ void DrawViewShell::GetSnapItemState( SfxItemSet &rSet )
Size(FuPoor::HITPIX,0)).Width());
sal_uInt16 nHelpLine;
- if ( !mpDrawView->PickHelpLine(aMPos, nHitLog, *GetActiveWindow(), nHelpLine, pPV) )
+ if ( !mpDrawView->PickHelpLine(aMPos, nHitLog, *GetActiveWindow()->GetOutDev(), nHelpLine, pPV) )
return;
const SdrHelpLine& rHelpLine = (pPV->GetHelpLines())[nHelpLine];
diff --git a/sd/source/ui/view/drviews4.cxx b/sd/source/ui/view/drviews4.cxx
index 01d9d88ac24a..2baed5669dae 100644
--- a/sd/source/ui/view/drviews4.cxx
+++ b/sd/source/ui/view/drviews4.cxx
@@ -442,7 +442,7 @@ void DrawViewShell::MouseMove(const MouseEvent& rMEvt, ::sd::Window* pWin)
{
for( ::tools::Long nX = nStartX; nX <= nEndX; nX++ )
{
- const Color aCol( pWin->GetPixel( pWin->PixelToLogic( Point( nX, nY ) ) ) );
+ const Color aCol( pWin->GetOutDev()->GetPixel( pWin->PixelToLogic( Point( nX, nY ) ) ) );
nRed += aCol.GetRed();
nGreen += aCol.GetGreen();
@@ -572,7 +572,7 @@ void DrawViewShell::Command(const CommandEvent& rCEvt, ::sd::Window* pWin)
pFldItem = pOLV->GetFieldAtSelection();
// helper line
- if ( mpDrawView->PickHelpLine( aMPos, nHitLog, *GetActiveWindow(), nHelpLine, pPV) )
+ if ( mpDrawView->PickHelpLine( aMPos, nHitLog, *GetActiveWindow()->GetOutDev(), nHelpLine, pPV) )
{
ShowSnapLineContextMenu(*pPV, nHelpLine, rCEvt.GetMousePosPixel());
return;
diff --git a/sd/source/ui/view/drviews5.cxx b/sd/source/ui/view/drviews5.cxx
index 7d92475aac0e..7347eefbbb84 100644
--- a/sd/source/ui/view/drviews5.cxx
+++ b/sd/source/ui/view/drviews5.cxx
@@ -284,8 +284,8 @@ void DrawViewShell::ReadFrameViewData(FrameView* pView)
SwitchPage(nSelectedPage);
// restore DrawMode for 'normal' window
- if(GetActiveWindow()->GetDrawMode() != pView->GetDrawMode())
- GetActiveWindow()->SetDrawMode(pView->GetDrawMode());
+ if(GetActiveWindow()->GetOutDev()->GetDrawMode() != pView->GetDrawMode())
+ GetActiveWindow()->GetOutDev()->SetDrawMode(pView->GetDrawMode());
if ( mpDrawView->IsDesignMode() != pView->IsDesignMode() )
{
@@ -387,8 +387,8 @@ void DrawViewShell::WriteFrameViewData()
mpFrameView->SetActiveLayer( mpDrawView->GetActiveLayer() );
// store DrawMode for 'normal' window
- if(mpFrameView->GetDrawMode() != GetActiveWindow()->GetDrawMode())
- mpFrameView->SetDrawMode(GetActiveWindow()->GetDrawMode());
+ if(mpFrameView->GetDrawMode() != GetActiveWindow()->GetOutDev()->GetDrawMode())
+ mpFrameView->SetDrawMode(GetActiveWindow()->GetOutDev()->GetDrawMode());
}
void DrawViewShell::PrePaint()
@@ -417,7 +417,7 @@ void DrawViewShell::Paint(const ::tools::Rectangle& rRect, ::sd::Window* pWin)
character in a symbol font */
GetDoc()->GetDrawOutliner().SetDefaultLanguage( Application::GetSettings().GetLanguageTag().getLanguageType() );
- mpDrawView->CompleteRedraw( pWin, vcl::Region( rRect ) );
+ mpDrawView->CompleteRedraw( pWin->GetOutDev(), vcl::Region( rRect ) );
}
/**
@@ -555,7 +555,7 @@ void DrawViewShell::ReadUserDataSequence ( const css::uno::Sequence < css::beans
if (pView)
{
- pView->VisAreaChanged(GetActiveWindow());
+ pView->VisAreaChanged(GetActiveWindow()->GetOutDev());
}
SetZoomRect(aVisArea);
diff --git a/sd/source/ui/view/drviewsa.cxx b/sd/source/ui/view/drviewsa.cxx
index 92174788cfc6..30acb21ca00f 100644
--- a/sd/source/ui/view/drviewsa.cxx
+++ b/sd/source/ui/view/drviewsa.cxx
@@ -214,7 +214,7 @@ void DrawViewShell::Construct(DrawDocShell* pDocSh, PageKind eInitialPageKind)
GetDoc()->CreateFirstPages();
- mpDrawView.reset( new DrawView(pDocSh, GetActiveWindow(), this) );
+ mpDrawView.reset( new DrawView(pDocSh, GetActiveWindow()->GetOutDev(), this) );
mpView = mpDrawView.get(); // Pointer of base class ViewShell
mpDrawView->SetSwapAsynchron(); // Asynchronous load of graphics
diff --git a/sd/source/ui/view/drviewsf.cxx b/sd/source/ui/view/drviewsf.cxx
index c9cbbbd0b77d..52955fc247cf 100644
--- a/sd/source/ui/view/drviewsf.cxx
+++ b/sd/source/ui/view/drviewsf.cxx
@@ -179,7 +179,7 @@ void DrawViewShell::GetCtrlState(SfxItemSet &rSet)
SfxItemState::DEFAULT == rSet.GetItemState( SID_OUTPUT_QUALITY_BLACKWHITE ) ||
SfxItemState::DEFAULT == rSet.GetItemState( SID_OUTPUT_QUALITY_CONTRAST ) )
{
- const sal_uLong nMode = static_cast<sal_Int32>(GetActiveWindow()->GetDrawMode());
+ const sal_uLong nMode = static_cast<sal_Int32>(GetActiveWindow()->GetOutDev()->GetDrawMode());
rSet.Put( SfxBoolItem( SID_OUTPUT_QUALITY_COLOR, sal_uLong(OUTPUT_DRAWMODE_COLOR) == nMode ) );
rSet.Put( SfxBoolItem( SID_OUTPUT_QUALITY_GRAYSCALE, static_cast<sal_uLong>(OUTPUT_DRAWMODE_GRAYSCALE) == nMode ) );
rSet.Put( SfxBoolItem( SID_OUTPUT_QUALITY_BLACKWHITE, static_cast<sal_uLong>(OUTPUT_DRAWMODE_BLACKWHITE) == nMode ) );
diff --git a/sd/source/ui/view/drviewsh.cxx b/sd/source/ui/view/drviewsh.cxx
index 72013d5fd99d..e6c3cc8e7f20 100644
--- a/sd/source/ui/view/drviewsh.cxx
+++ b/sd/source/ui/view/drviewsh.cxx
@@ -75,12 +75,12 @@ void DrawViewShell::MakeVisible(const ::tools::Rectangle& rRect, vcl::Window& rW
bool bTiledRendering = comphelper::LibreOfficeKit::isActive() && !rWin.IsMapModeEnabled();
if (bTiledRendering)
{
- rWin.Push(PushFlags::MAPMODE);
+ rWin.GetOutDev()->Push(PushFlags::MAPMODE);
rWin.EnableMapMode();
}
::tools::Rectangle aVisArea(rWin.PixelToLogic(::tools::Rectangle(Point(0,0), aVisSizePixel)));
if (bTiledRendering)
- rWin.Pop();
+ rWin.GetOutDev()->Pop();
Size aVisAreaSize(aVisArea.GetSize());
if ( aVisArea.IsInside(rRect) )
diff --git a/sd/source/ui/view/outlview.cxx b/sd/source/ui/view/outlview.cxx
index 9c0c16ed9462..210df149cd8a 100644
--- a/sd/source/ui/view/outlview.cxx
+++ b/sd/source/ui/view/outlview.cxx
@@ -70,7 +70,7 @@ namespace sd {
#define PROCESS_WITH_PROGRESS_THRESHOLD 5
OutlineView::OutlineView( DrawDocShell& rDocSh, vcl::Window* pWindow, OutlineViewShell& rOutlineViewShell)
-: ::sd::View(*rDocSh.GetDoc(), pWindow, &rOutlineViewShell)
+: ::sd::View(*rDocSh.GetDoc(), pWindow->GetOutDev(), &rOutlineViewShell)
, mrOutlineViewShell(rOutlineViewShell)
, mrOutliner(*mrDoc.GetOutliner())
, mnPagesToProcess(0)
@@ -243,7 +243,7 @@ void OutlineView::DeleteWindowFromPaintView(OutputDevice* pWin)
{
pWindow = mpOutlinerViews[nView]->GetWindow();
- if (pWindow == pWin)
+ if (pWindow->GetOutDev() == pWin)
{
mrOutliner.RemoveView( mpOutlinerViews[nView].get() );
mpOutlinerViews[nView].reset();
diff --git a/sd/source/ui/view/sdview.cxx b/sd/source/ui/view/sdview.cxx
index 5a2a0be72ce7..d36f81b1a604 100644
--- a/sd/source/ui/view/sdview.cxx
+++ b/sd/source/ui/view/sdview.cxx
@@ -1256,7 +1256,8 @@ void View::ChangeMarkedObjectsBulletsNumbering(
const SvxNumRule* pNumRule )
{
SdrModel* pSdrModel = GetModel();
- vcl::Window* pWindow = dynamic_cast< vcl::Window* >(GetFirstOutputDevice());
+ OutputDevice* pOut = GetFirstOutputDevice();
+ vcl::Window* pWindow = pOut ? pOut->GetOwnerWindow() : nullptr;
if (!pSdrModel || !pWindow)
return;
diff --git a/sd/source/ui/view/sdview4.cxx b/sd/source/ui/view/sdview4.cxx
index 882258bd9231..6a7c49224052 100644
--- a/sd/source/ui/view/sdview4.cxx
+++ b/sd/source/ui/view/sdview4.cxx
@@ -177,7 +177,7 @@ SdrGrafObj* View::InsertGraphic( const Graphic& rGraphic, sal_Int8& rAction,
{
::OutputDevice* pOutDev = nullptr;
if( mpViewSh )
- pOutDev = mpViewSh->GetActiveWindow();
+ pOutDev = mpViewSh->GetActiveWindow()->GetOutDev();
if( !pOutDev )
pOutDev = Application::GetDefaultDevice();
diff --git a/sd/source/ui/view/sdwindow.cxx b/sd/source/ui/view/sdwindow.cxx
index eceb4254a1fe..765bf7bed661 100644
--- a/sd/source/ui/view/sdwindow.cxx
+++ b/sd/source/ui/view/sdwindow.cxx
@@ -84,7 +84,7 @@ Window::Window(vcl::Window* pParent)
// adjust contrast mode initially
bool bUseContrast = GetSettings().GetStyleSettings().GetHighContrastMode();
- SetDrawMode( bUseContrast
+ GetOutDev()->SetDrawMode( bUseContrast
? sd::OUTPUT_DRAWMODE_CONTRAST
: sd::OUTPUT_DRAWMODE_COLOR );
@@ -353,7 +353,7 @@ void Window::SetCenterAllowed (bool bIsAllowed)
// Update the view's snapping to the new zoom factor.
if ( auto pDrawViewShell = dynamic_cast< DrawViewShell *>( mpViewShell ) )
- pDrawViewShell->GetView()->RecalcLogicSnapMagnetic(*this);
+ pDrawViewShell->GetView()->RecalcLogicSnapMagnetic(*GetOutDev());
// Return the zoom factor just in case it has been changed above to lie
// inside the valid range.
@@ -797,7 +797,7 @@ void Window::DataChanged( const DataChangedEvent& rDCEvt )
if( dynamic_cast< DrawViewShell *>( mpViewShell ) != nullptr )
{
- SetDrawMode( nOutputMode );
+ GetOutDev()->SetDrawMode( nOutputMode );
mpViewShell->GetFrameView()->SetDrawMode( nOutputMode );
Invalidate();
}
diff --git a/sd/source/ui/view/viewoverlaymanager.cxx b/sd/source/ui/view/viewoverlaymanager.cxx
index 95c34d0655bd..3e7f187ea506 100644
--- a/sd/source/ui/view/viewoverlaymanager.cxx
+++ b/sd/source/ui/view/viewoverlaymanager.cxx
@@ -202,7 +202,7 @@ void ImageButtonHdl::ShowTip()
else if (mnHighlightId == 3)
aHelpPos.Move(maImageSize.Width(), maImageSize.Height());
::tools::Rectangle aLogicPix(aHelpPos, maImageSize);
- vcl::Window* pWindow = static_cast<vcl::Window*>(pHdlList->GetView()->GetFirstOutputDevice());
+ vcl::Window* pWindow = pHdlList->GetView()->GetFirstOutputDevice()->GetOwnerWindow();
::tools::Rectangle aScreenRect(pWindow->OutputToScreenPixel(aLogicPix.TopLeft()),
pWindow->OutputToScreenPixel(aLogicPix.BottomRight()));
Help::ShowQuickHelp(pWindow, aScreenRect, aHelpText);
diff --git a/sd/source/ui/view/viewshe2.cxx b/sd/source/ui/view/viewshe2.cxx
index 818cc4e8d298..0837c0ecbb8a 100644
--- a/sd/source/ui/view/viewshe2.cxx
+++ b/sd/source/ui/view/viewshe2.cxx
@@ -164,7 +164,7 @@ void ViewShell::VirtHScrollHdl(ScrollBar* pHScroll)
if (pView)
{
- pView->VisAreaChanged(GetActiveWindow());
+ pView->VisAreaChanged(GetActiveWindow()->GetOutDev());
}
if (pOLV)
@@ -221,7 +221,7 @@ void ViewShell::VirtVScrollHdl(ScrollBar* pVScroll)
if (pView)
{
- pView->VisAreaChanged(GetActiveWindow());
+ pView->VisAreaChanged(GetActiveWindow()->GetOutDev());
}
if (pOLV)
@@ -300,7 +300,7 @@ void ViewShell::Scroll(::tools::Long nScrollX, ::tools::Long nScrollY)
::sd::View* pView = GetView();
if (pView)
{
- pView->VisAreaChanged(GetActiveWindow());
+ pView->VisAreaChanged(GetActiveWindow()->GetOutDev());
}
if (mbHasRulers)
@@ -342,7 +342,7 @@ void ViewShell::SetZoom(::tools::Long nZoom)
::sd::View* pView = GetView();
if (pView)
{
- pView->VisAreaChanged(GetActiveWindow());
+ pView->VisAreaChanged(GetActiveWindow()->GetOutDev());
}
UpdateScrollBars();
@@ -398,7 +398,7 @@ void ViewShell::SetZoomRect(const ::tools::Rectangle& rZoomRect)
::sd::View* pView = GetView();
if (pView)
{
- pView->VisAreaChanged(GetActiveWindow());
+ pView->VisAreaChanged(GetActiveWindow()->GetOutDev());
}
UpdateScrollBars();
@@ -430,7 +430,7 @@ void ViewShell::InitWindows(const Point& rViewOrigin, const Size& rViewSize,
::sd::View* pView = GetView();
if (pView)
{
- pView->VisAreaChanged(GetActiveWindow());
+ pView->VisAreaChanged(GetActiveWindow()->GetOutDev());
}
}
@@ -579,7 +579,7 @@ void ViewShell::SetActiveWindow (::sd::Window* pWin)
::sd::View* pView = GetView();
if (pView)
{
- pView->SetActualWin(pWin);
+ pView->SetActualWin(pWin->GetOutDev());
}
if(HasCurrentFunction())
{
@@ -939,7 +939,7 @@ void ViewShell::SetWinViewPos(const Point& rWinPos)
::sd::View* pView = GetView();
if (pView)
{
- pView->VisAreaChanged(GetActiveWindow());
+ pView->VisAreaChanged(GetActiveWindow()->GetOutDev());
}
}
diff --git a/sd/source/ui/view/viewshel.cxx b/sd/source/ui/view/viewshel.cxx
index eeec0ad78447..890b9ddde1b2 100644
--- a/sd/source/ui/view/viewshel.cxx
+++ b/sd/source/ui/view/viewshel.cxx
@@ -896,7 +896,7 @@ void ViewShell::Resize()
::sd::View* pView = GetView();
if (pView)
- pView->VisAreaChanged(GetActiveWindow());
+ pView->VisAreaChanged(GetActiveWindow()->GetOutDev());
}
SvBorder ViewShell::GetBorder()
@@ -1351,7 +1351,7 @@ void ViewShell::ExecReq( SfxRequest& rReq )
case SID_OUTPUT_QUALITY_CONTRAST: nMode = OUTPUT_DRAWMODE_CONTRAST; break;
}
- GetActiveWindow()->SetDrawMode( nMode );
+ GetActiveWindow()->GetOutDev()->SetDrawMode( nMode );
mpFrameView->SetDrawMode( nMode );
GetActiveWindow()->Invalidate();