Kaydet (Commit) 20dd938d authored tarafından Stephan Bergmann's avatar Stephan Bergmann

Remove unncessary, wrong downcast

...which caused

> sd/source/core/sdpage2.cxx:151:28: runtime error: downcast of address 0x611000ccf8c0 which does not point to an object of type 'SdrTextObj'
> 0x611000ccf8c0: note: object is of type 'SdrPageObj'
>  08 07 80 35  10 3e 04 ba 4f 7f 00 00  c0 1b 2c 00 b0 60 00 00  00 00 00 00 00 00 00 00  70 1c 2c 00
>               ^~~~~~~~~~~~~~~~~~~~~~~
>               vptr for 'SdrPageObj'
>  SdPage::SetPresentationLayout(rtl::OUString const&, bool, bool, bool) sd/source/core/sdpage2.cxx:151:28
>  SdDrawDocument::SetMasterPage(unsigned short, rtl::OUString const&, SdDrawDocument*, bool, bool) sd/source/core/drawdoc3.cxx:1746:13
>  AssistentDlgImpl::UpdatePreview(bool) sd/source/ui/dlg/dlgass.cxx:1513:13
>  [...]

Change-Id: I07afc4cd7ef0a0a32768db59b72ca94edd4026df
üst 9b322ace
...@@ -148,7 +148,7 @@ void SdPage::SetPresentationLayout(const OUString& rLayoutName, ...@@ -148,7 +148,7 @@ void SdPage::SetPresentationLayout(const OUString& rLayoutName,
for (size_t nObj = 0; nObj < nObjCount; ++nObj) for (size_t nObj = 0; nObj < nObjCount; ++nObj)
{ {
SdrTextObj* pObj = static_cast<SdrTextObj*>( GetObj(nObj) ); auto pObj = GetObj(nObj);
if (pObj->GetObjInventor() == SdrInventor && if (pObj->GetObjInventor() == SdrInventor &&
pObj->GetObjIdentifier() == OBJ_OUTLINETEXT) pObj->GetObjIdentifier() == OBJ_OUTLINETEXT)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment