diff options
-rw-r--r-- | editeng/source/editeng/impedit.hxx | 1 | ||||
-rw-r--r-- | editeng/source/editeng/impedit2.cxx | 4 |
2 files changed, 4 insertions, 1 deletions
diff --git a/editeng/source/editeng/impedit.hxx b/editeng/source/editeng/impedit.hxx index 35121b5898c2..ffcda876992d 100644 --- a/editeng/source/editeng/impedit.hxx +++ b/editeng/source/editeng/impedit.hxx @@ -420,6 +420,7 @@ private: VclPtr< VirtualDevice> pVirtDev; VclPtr< OutputDevice > pRefDev; + VclPtr<VirtualDevice> mpOwnDev; svtools::ColorConfig* pColorConfig; mutable SvtCTLOptions* pCTLOptions; diff --git a/editeng/source/editeng/impedit2.cxx b/editeng/source/editeng/impedit2.cxx index 1c56dfbaf18e..5bbb325cc854 100644 --- a/editeng/source/editeng/impedit2.cxx +++ b/editeng/source/editeng/impedit2.cxx @@ -176,6 +176,7 @@ ImpEditEngine::~ImpEditEngine() bDowning = true; SetUpdateMode( false ); + mpOwnDev.disposeAndClear(); pVirtDev.disposeAndClear(); delete pEmptyItemSet; delete pUndoManager; @@ -207,7 +208,8 @@ void ImpEditEngine::SetRefMapMode( const MapMode& rMapMode ) if ( GetRefDevice()->GetMapMode() == rMapMode ) return; - pRefDev = VclPtr<VirtualDevice>::Create(); + mpOwnDev = VclPtr<VirtualDevice>::Create(); + pRefDev = mpOwnDev; pRefDev->SetMapMode( MapUnit::MapTwip ); SetRefDevice( pRefDev ); |