diff options
Diffstat (limited to 'sc/source/ui/view/viewfun5.cxx')
-rw-r--r-- | sc/source/ui/view/viewfun5.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sc/source/ui/view/viewfun5.cxx b/sc/source/ui/view/viewfun5.cxx index 758c0621478d..7aa96e344dbb 100644 --- a/sc/source/ui/view/viewfun5.cxx +++ b/sc/source/ui/view/viewfun5.cxx @@ -336,8 +336,9 @@ bool ScViewFunc::PasteDataFormat( SotClipboardFormatId nFormatId, && aDataHelper.GetString( nFormatId, *pStrBuffer )) { // Do CSV dialog if more than one line. But not if invoked from Automation. + const SfxViewShell* pViewShell = SfxViewShell::Current(); sal_Int32 nDelim = pStrBuffer->indexOf('\n'); - if (!comphelper::LibreOfficeKit::isMobilePhone(SfxLokHelper::getView()) && !comphelper::Automation::AutomationInvokedZone::isActive() + if (!(pViewShell && pViewShell->isLOKMobilePhone()) && !comphelper::Automation::AutomationInvokedZone::isActive() && nDelim >= 0 && nDelim != pStrBuffer->getLength () - 1) { vcl::Window* pParent = GetActiveWin(); |