summaryrefslogtreecommitdiff
path: root/sd/source/ui/dlg/docprev.cxx
diff options
context:
space:
mode:
authorMichael Meeks <michael.meeks@collabora.com>2015-03-19 15:39:43 +0000
committerMichael Meeks <michael.meeks@collabora.com>2015-04-10 12:17:54 +0100
commit8fa63f31ab84131fc1551563ae5d9bf86208c906 (patch)
tree7cecdf6f9e4bce0f68779628152676ec21ff762b /sd/source/ui/dlg/docprev.cxx
parente1b8e36a2693102664b8afe16ec321ef63e234aa (diff)
Fix OutputDevice members / stack allocation: slideshow, starmath, sd, sc.
Change-Id: I6d6d41b8a6501ce7d35c78e5b730ea45143d6b73
Diffstat (limited to 'sd/source/ui/dlg/docprev.cxx')
-rw-r--r--sd/source/ui/dlg/docprev.cxx18
1 files changed, 9 insertions, 9 deletions
diff --git a/sd/source/ui/dlg/docprev.cxx b/sd/source/ui/dlg/docprev.cxx
index 9669499d1172..f772bb97c22e 100644
--- a/sd/source/ui/dlg/docprev.cxx
+++ b/sd/source/ui/dlg/docprev.cxx
@@ -241,17 +241,17 @@ void SdDocPreviewWin::updateViewSettings()
pMtf = new GDIMetaFile;
- VirtualDevice aVDev;
+ ScopedVclPtr<VirtualDevice> pVDev(new VirtualDevice());
const Fraction aFrac( pDoc->GetScaleFraction() );
const MapMode aMap( pDoc->GetScaleUnit(), Point(), aFrac, aFrac );
- aVDev.SetMapMode( aMap );
+ pVDev->SetMapMode( aMap );
// Disable output, as we only want to record a metafile
- aVDev.EnableOutput( false );
+ pVDev->EnableOutput( false );
- pMtf->Record( &aVDev );
+ pMtf->Record( pVDev );
::sd::DrawView* pView = new ::sd::DrawView(pDocShell, this, NULL);
@@ -267,18 +267,18 @@ void SdDocPreviewWin::updateViewSettings()
const Rectangle aClipRect( aNewOrg, aNewSize );
MapMode aVMap( aMap );
- aVDev.Push();
+ pVDev->Push();
aVMap.SetOrigin( Point( -aNewOrg.X(), -aNewOrg.Y() ) );
- aVDev.SetRelativeMapMode( aVMap );
- aVDev.IntersectClipRegion( aClipRect );
+ pVDev->SetRelativeMapMode( aVMap );
+ pVDev->IntersectClipRegion( aClipRect );
// Use new StandardCheckVisisbilityRedirector
StandardCheckVisisbilityRedirector aRedirector;
const Rectangle aRedrawRectangle = Rectangle( Point(), aNewSize );
vcl::Region aRedrawRegion(aRedrawRectangle);
- pView->SdrPaintView::CompleteRedraw(&aVDev,aRedrawRegion,&aRedirector);
+ pView->SdrPaintView::CompleteRedraw(pVDev,aRedrawRegion,&aRedirector);
- aVDev.Pop();
+ pVDev->Pop();
pMtf->Stop();
pMtf->WindStart();