summaryrefslogtreecommitdiff
path: root/sc/source
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source')
-rw-r--r--sc/source/ui/app/inputhdl.cxx8
1 files changed, 8 insertions, 0 deletions
diff --git a/sc/source/ui/app/inputhdl.cxx b/sc/source/ui/app/inputhdl.cxx
index 0fb604520ac2..94e68ac4c00c 100644
--- a/sc/source/ui/app/inputhdl.cxx
+++ b/sc/source/ui/app/inputhdl.cxx
@@ -4258,6 +4258,14 @@ void ScInputHandler::NotifyChange( const ScInputHdlState* pState,
{
EditView* pActiveView = pTopView ? pTopView : pTableView;
ESelection aSel = pActiveView ? pActiveView->GetSelection() : ESelection();
+
+ // if we switched content completly - don't send huge numbers
+ if (aSel.nStartPara == EE_PARA_NOT_FOUND)
+ aSel.nStartPara = 0;
+
+ if (aSel.nEndPara == EE_PARA_NOT_FOUND)
+ aSel.nEndPara = 0;
+
ScInputHandler::LOKSendFormulabarUpdate(pActiveViewSh, aString, aSel);
// TODO: deprecated?
pActiveViewSh->libreOfficeKitViewCallback(LOK_CALLBACK_CELL_FORMULA, aString.toUtf8().getStr());