diff options
Diffstat (limited to 'sw/source/ui/shells/grfsh.cxx')
-rw-r--r-- | sw/source/ui/shells/grfsh.cxx | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sw/source/ui/shells/grfsh.cxx b/sw/source/ui/shells/grfsh.cxx index 33108c062559..ce3ca38537f2 100644 --- a/sw/source/ui/shells/grfsh.cxx +++ b/sw/source/ui/shells/grfsh.cxx @@ -266,7 +266,7 @@ void SwGrfShell::Execute(SfxRequest &rReq) const GraphicObject* pGrfObj = rSh.GetGraphicObj(); if ( pGrfObj ) { - aSet.Put( SvxBrushItem( *pGrfObj, GPOS_LT, + aSet.Put( SvxBrushItem( GraphicObject::Create(*pGrfObj), GPOS_LT, SID_ATTR_GRAF_GRAPHIC ) ); } } @@ -551,11 +551,12 @@ void SwGrfShell::ExecAttr( SfxRequest &rReq ) const GraphicObject* pFilterObj( GetShell().GetGraphicObj() ); if ( pFilterObj ) { - GraphicObject aFilterObj( *pFilterObj ); + Graphic* pGraphObj = new Graphic(pFilterObj->GetGraphic()); if( SVX_GRAPHICFILTER_ERRCODE_NONE == - SvxGraphicFilter::ExecuteGrfFilterSlot( rReq, aFilterObj )) + SvxGraphicFilter::ExecuteGrfFilterSlot( rReq, &pGraphObj )) GetShell().ReRead( aEmptyStr, aEmptyStr, - &aFilterObj.GetGraphic() ); + &(*pGraphObj) ); + delete pGraphObj; } } break; |