| commit | f00fbd068a3b98b4c2ab98aea01ed6a2ff1b8009 | [log] |
|---|---|---|
| author | Caolán McNamara <caolanm@redhat.com> | Tue Dec 22 14:14:39 2020 +0000 |
| committer | Caolán McNamara <caolanm@redhat.com> | Wed Dec 23 15:03:57 2020 +0100 |
| tree | 5aff8c9595cb8706db8098af2fbfd13b07e8a082 | |
| parent | 2bd03b6de32a8bd6ff7d075752eda051a43e4add [diff] |
tdf#138457 Cursor position wrong when using functions in a writer table Change-Id: I70156d8492afbab2c5993e1627a024ef8e07c492 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108175 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
diff --git a/sw/source/uibase/inc/inputwin.hxx b/sw/source/uibase/inc/inputwin.hxx index 08dcea7..ab18e21 100644 --- a/sw/source/uibase/inc/inputwin.hxx +++ b/sw/source/uibase/inc/inputwin.hxx
@@ -74,7 +74,15 @@ public: void replace_selection(const OUString& rText) { int nStartPos, nEndPos; m_xWidget->get_selection_bounds(nStartPos, nEndPos); if (nStartPos > nEndPos) std::swap(nStartPos, nEndPos); m_xWidget->replace_selection(rText); nStartPos = nStartPos + rText.getLength(); m_xWidget->select_region(nStartPos, nStartPos); } void select_region(int nStartPos, int nEndPos)