diff options
Diffstat (limited to 'sd/source/ui/view/sdview4.cxx')
-rw-r--r-- | sd/source/ui/view/sdview4.cxx | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/sd/source/ui/view/sdview4.cxx b/sd/source/ui/view/sdview4.cxx index f98a8ab1b216..fb17fcc2df24 100644 --- a/sd/source/ui/view/sdview4.cxx +++ b/sd/source/ui/view/sdview4.cxx @@ -116,7 +116,10 @@ SdrGrafObj* View::InsertGraphic( const Graphic& rGraphic, sal_Int8& rAction, } else { - pNewGrafObj = new SdrGrafObj( rGraphic, pPickObj->GetLogicRect() ); + pNewGrafObj = new SdrGrafObj( + getSdrModelFromSdrView(), + rGraphic, + pPickObj->GetLogicRect()); pNewGrafObj->SetEmptyPresObj(true); } @@ -189,7 +192,10 @@ SdrGrafObj* View::InsertGraphic( const Graphic& rGraphic, sal_Int8& rAction, MapMode( MapUnit::Map100thMM ) ); } - pNewGrafObj = new SdrGrafObj( rGraphic, ::tools::Rectangle( rPos, aSize ) ); + pNewGrafObj = new SdrGrafObj( + getSdrModelFromSdrView(), + rGraphic, + ::tools::Rectangle(rPos, aSize)); SdrPage* pPage = pPV->GetPage(); Size aPageSize( pPage->GetSize() ); aPageSize.AdjustWidth( -(pPage->GetLeftBorder() + pPage->GetRightBorder()) ); @@ -329,7 +335,9 @@ SdrMediaObj* View::InsertMediaObj( const OUString& rMediaURL, const OUString& rM pUserCall = pPickObj->GetUserCall(); // ReplaceObjectAtView can free pPickObj } - pNewMediaObj = new SdrMediaObj( aRect ); + pNewMediaObj = new SdrMediaObj( + getSdrModelFromSdrView(), + aRect); bool bIsPres = false; if( pPickObj ) @@ -529,7 +537,11 @@ IMPL_LINK_NOARG(View, DropInsertFileHdl, Timer *, void) aRect = ::tools::Rectangle( maDropPos, aSize ); - SdrOle2Obj* pOleObj = new SdrOle2Obj( svt::EmbeddedObjectRef( xObj, nAspect ), aName, aRect ); + SdrOle2Obj* pOleObj = new SdrOle2Obj( + getSdrModelFromSdrView(), + svt::EmbeddedObjectRef(xObj, nAspect), + aName, + aRect); SdrInsertFlags nOptions = SdrInsertFlags::SETDEFLAYER; if (mpViewSh != nullptr) |