summaryrefslogtreecommitdiff
path: root/sd
diff options
context:
space:
mode:
Diffstat (limited to 'sd')
-rw-r--r--sd/source/ui/inc/unomodel.hxx2
-rw-r--r--sd/source/ui/unoidl/unomodel.cxx5
2 files changed, 4 insertions, 3 deletions
diff --git a/sd/source/ui/inc/unomodel.hxx b/sd/source/ui/inc/unomodel.hxx
index 381b22be955f..0baaa22eda96 100644
--- a/sd/source/ui/inc/unomodel.hxx
+++ b/sd/source/ui/inc/unomodel.hxx
@@ -130,7 +130,7 @@ private:
protected:
/** abstract SdrModel provider */
- virtual SdrModel* getSdrModelFromUnoModel() const override;
+ virtual SdrModel& getSdrModelFromUnoModel() const override;
public:
SdXImpressDocument(::sd::DrawDocShell* pShell, bool bClipBoard);
diff --git a/sd/source/ui/unoidl/unomodel.cxx b/sd/source/ui/unoidl/unomodel.cxx
index b6ee7d5d1122..dc53abb989b5 100644
--- a/sd/source/ui/unoidl/unomodel.cxx
+++ b/sd/source/ui/unoidl/unomodel.cxx
@@ -2714,9 +2714,10 @@ void SdXImpressDocument::initializeDocument()
}
}
-SdrModel* SdXImpressDocument::getSdrModelFromUnoModel() const
+SdrModel& SdXImpressDocument::getSdrModelFromUnoModel() const
{
- return GetDoc();
+ OSL_ENSURE(GetDoc(), "No SdrModel in draw/Impress, should not happen");
+ return *GetDoc(); // TTTT should be reference
}
void SAL_CALL SdXImpressDocument::dispose()