summaryrefslogtreecommitdiff
path: root/sd/source/ui/docshell/docshel3.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sd/source/ui/docshell/docshel3.cxx')
-rw-r--r--sd/source/ui/docshell/docshel3.cxx11
1 files changed, 5 insertions, 6 deletions
diff --git a/sd/source/ui/docshell/docshel3.cxx b/sd/source/ui/docshell/docshel3.cxx
index c49841bcb969..de61d9c25eb0 100644
--- a/sd/source/ui/docshell/docshel3.cxx
+++ b/sd/source/ui/docshell/docshel3.cxx
@@ -145,9 +145,9 @@ void DrawDocShell::Execute( SfxRequest& rReq )
if (pReqArgs)
{
- const SvxSearchItem* pSearchItem = static_cast<const SvxSearchItem*>( &pReqArgs->Get(SID_SEARCH_ITEM) );
+ const SvxSearchItem & rSearchItem = pReqArgs->Get(SID_SEARCH_ITEM);
- SD_MOD()->SetSearchItem(std::unique_ptr<SvxSearchItem>(static_cast<SvxSearchItem*>(pSearchItem->Clone())));
+ SD_MOD()->SetSearchItem(std::unique_ptr<SvxSearchItem>(static_cast<SvxSearchItem*>(rSearchItem.Clone())));
}
rReq.Done();
@@ -208,11 +208,10 @@ void DrawDocShell::Execute( SfxRequest& rReq )
if( xFuSearch.is() )
{
- const SvxSearchItem* pSearchItem =
- static_cast<const SvxSearchItem*>( &pReqArgs->Get(SID_SEARCH_ITEM) );
+ const SvxSearchItem& rSearchItem = pReqArgs->Get(SID_SEARCH_ITEM);
- SD_MOD()->SetSearchItem(std::unique_ptr<SvxSearchItem>(static_cast<SvxSearchItem*>( pSearchItem->Clone() )));
- xFuSearch->SearchAndReplace(pSearchItem);
+ SD_MOD()->SetSearchItem(std::unique_ptr<SvxSearchItem>(static_cast<SvxSearchItem*>( rSearchItem.Clone() )));
+ xFuSearch->SearchAndReplace(&rSearchItem);
}
}