editeng/source/editeng/editview.cxx | 5 +++++ editeng/source/editeng/impedit.cxx | 9 +++++++-- sc/source/ui/app/inputwin.cxx | 2 ++ 3 files changed, 14 insertions(+), 2 deletions(-)
New commits: commit ee81e26b1ef6e9e2dafb5bfb85014a51d116e705 Author: Marco Cecchetti <marco.cecche...@collabora.com> AuthorDate: Thu Mar 5 11:43:51 2020 +0100 Commit: Jan Holesovsky <ke...@collabora.com> CommitDate: Wed Mar 18 21:48:26 2020 +0100 lok: get the formula input bar focused after inserting '=' Change-Id: I7f86ea7135fcb4071cc0162c233c63be6c9485bd diff --git a/sc/source/ui/app/inputwin.cxx b/sc/source/ui/app/inputwin.cxx index fa84747e17be..161cb90806c1 100644 --- a/sc/source/ui/app/inputwin.cxx +++ b/sc/source/ui/app/inputwin.cxx @@ -450,6 +450,8 @@ void ScInputWindow::Select() EditView* pView = aTextWindow.GetEditView(); if (pView) { + if (comphelper::LibreOfficeKit::isActive()) + TextGrabFocus(); pView->SetSelection( ESelection(0, nStartPos, 0, nEndPos) ); pScMod->InputChanged(pView); SetOkCancelMode(); commit 3a7486b16ee89031ef9ae36a07474a8fa13b7de3 Author: Marco Cecchetti <marco.cecche...@collabora.com> AuthorDate: Thu Mar 5 11:42:29 2020 +0100 Commit: Jan Holesovsky <ke...@collabora.com> CommitDate: Wed Mar 18 21:47:48 2020 +0100 lok: avoid to grab the focus from the formula bar Change-Id: I13a2766e3c5dfd67cc89b5303e4a06f058b43891 diff --git a/editeng/source/editeng/editview.cxx b/editeng/source/editeng/editview.cxx index 24d0947d7de5..66c8ed6f5b4a 100644 --- a/editeng/source/editeng/editview.cxx +++ b/editeng/source/editeng/editview.cxx @@ -486,6 +486,11 @@ void EditView::ShowCursor( bool bGotoCursor, bool bForceVisCursor, bool bActivat if (pParent && pParent->GetLOKWindowId() != 0) return; + // We need to avoid to grab the focus from the formula bar + vcl::Window* pWindow = Application::GetFocusWindow(); + if (!pWindow || pWindow != pImpEditView->pOutWin) + return; + static const OString aPayload = OString::boolean(true); pImpEditView->mpViewShell->libreOfficeKitViewCallback(LOK_CALLBACK_CURSOR_VISIBLE, aPayload.getStr()); pImpEditView->mpViewShell->NotifyOtherViews(LOK_CALLBACK_VIEW_CURSOR_VISIBLE, "visible", aPayload); diff --git a/editeng/source/editeng/impedit.cxx b/editeng/source/editeng/impedit.cxx index c9ad00241a55..e5bf2f3d3cf3 100644 --- a/editeng/source/editeng/impedit.cxx +++ b/editeng/source/editeng/impedit.cxx @@ -1196,8 +1196,13 @@ void ImpEditView::ShowCursor( bool bGotoCursor, bool bForceVisCursor ) } } - SfxLokHelper::notifyVisCursorInvalidation(mpViewShell, sRect, bIsWrong, sHyperlink); - mpViewShell->NotifyOtherViews(LOK_CALLBACK_INVALIDATE_VIEW_CURSOR, "rectangle", sRect); + // We need to avoid to grab the focus from the formula bar + vcl::Window* pWindow = Application::GetFocusWindow(); + if (pWindow && pWindow == pOutWin) + { + SfxLokHelper::notifyVisCursorInvalidation(mpViewShell, sRect, bIsWrong, sHyperlink); + mpViewShell->NotifyOtherViews(LOK_CALLBACK_INVALIDATE_VIEW_CURSOR, "rectangle", sRect); + } } } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits