summaryrefslogtreecommitdiff
path: root/sc/source/ui/view/viewfun3.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2023-01-12 10:19:24 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2023-01-12 14:46:29 +0000
commit0ef626f2ff72c62ee42e74e2b58174c047e384cd (patch)
tree340e7159b07866c884a776282726af8a8a8e16b5 /sc/source/ui/view/viewfun3.cxx
parent5fd2f0b93bd7d38a277823bfc251c71da7a6f490 (diff)
override GetModel in ScDocShell
so we can avoid dynamic_cast and XUnoTunnel in various places Change-Id: I1f524270a8030106a2058691c3d89b90d46ed26f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145391 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sc/source/ui/view/viewfun3.cxx')
-rw-r--r--sc/source/ui/view/viewfun3.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/sc/source/ui/view/viewfun3.cxx b/sc/source/ui/view/viewfun3.cxx
index 9dd9b810273a..a19484aa9007 100644
--- a/sc/source/ui/view/viewfun3.cxx
+++ b/sc/source/ui/view/viewfun3.cxx
@@ -1448,7 +1448,7 @@ bool ScViewFunc::PasteFromClip( InsertDeleteFlags nFlags, ScDocument* pClipDoc,
if ( nFlags & InsertDeleteFlags::OBJECTS )
{
- ScModelObj* pModelObj = comphelper::getFromUnoTunnel<ScModelObj>( pDocSh->GetModel() );
+ ScModelObj* pModelObj = pDocSh->GetModel();
if ( pPage && pModelObj )
{
bool bSameDoc = ( rClipParam.getSourceDocID() == rDoc.GetDocumentID() );
@@ -1803,7 +1803,7 @@ void ScViewFunc::PostPasteFromClip(const ScRangeList& rPasteRanges, const ScMark
SelectionChanged(true);
- ScModelObj* pModelObj = HelperNotifyChanges::getModel(*pDocSh);
+ ScModelObj* pModelObj = pDocSh->GetModel();
ScRangeList aChangeRanges;
for (size_t i = 0, n = rPasteRanges.size(); i < n; ++i)