diff options
Diffstat (limited to 'sw/source/core/frmedt/fecopy.cxx')
-rw-r--r-- | sw/source/core/frmedt/fecopy.cxx | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/sw/source/core/frmedt/fecopy.cxx b/sw/source/core/frmedt/fecopy.cxx index abecc671a750..9eb869de51ec 100644 --- a/sw/source/core/frmedt/fecopy.cxx +++ b/sw/source/core/frmedt/fecopy.cxx @@ -1532,9 +1532,12 @@ bool SwFEShell::Paste(const Graphic &rGrf, const OUString& rURL) SdrObject* pObj = nullptr; SdrView *pView = Imp()->GetDrawView(); - bool bRet = 1 == pView->GetMarkedObjectList().GetMarkCount() && - (pObj = pView->GetMarkedObjectList().GetMark( 0 )->GetMarkedSdrObj())->IsClosedObj() && - dynamic_cast<const SdrOle2Obj*>( pObj) == nullptr; + bool bRet = 1 == pView->GetMarkedObjectList().GetMarkCount(); + if (bRet) + { + pObj = pView->GetMarkedObjectList().GetMark( 0 )->GetMarkedSdrObj(); + bRet = pObj->IsClosedObj() && dynamic_cast<const SdrOle2Obj*>( pObj) == nullptr; + } if( bRet && pObj ) { |