diff options
author | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2017-04-09 01:21:25 +0200 |
---|---|---|
committer | Katarina Behrens <Katarina.Behrens@cib.de> | 2017-04-12 12:00:21 +0200 |
commit | dcd9eef1727efb7a909f8009fde4f34f26139522 (patch) | |
tree | 456838ae014716f43cb8e634b469941ccfdf880d | |
parent | 9826eb9b6bad6f21801dd8a0016bb770085a9072 (diff) |
don't replace content of formula field when selecting range, tdf#58635
Change-Id: I85953fdd7c2b7f193b2a815564526d985ae2bba4
Reviewed-on: https://gerrit.libreoffice.org/36309
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
(cherry picked from commit 42aece949ec96c775b31216bddd723aa5321e966)
Reviewed-on: https://gerrit.libreoffice.org/36310
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
-rw-r--r-- | sc/source/ui/condformat/condformatdlg.cxx | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sc/source/ui/condformat/condformatdlg.cxx b/sc/source/ui/condformat/condformatdlg.cxx index b2c0a1c07dd8..9a416692a4fd 100644 --- a/sc/source/ui/condformat/condformatdlg.cxx +++ b/sc/source/ui/condformat/condformatdlg.cxx @@ -572,7 +572,10 @@ void ScCondFormatDlg::SetReference(const ScRange& rRef, ScDocument*) OUString aRefStr(rRef.Format(nFlags, mpViewData->GetDocument(), ScAddress::Details(mpViewData->GetDocument()->GetAddressConvention(), 0, 0))); - pEdit->SetRefString( aRefStr ); + if (pEdit != mpEdRange) + pEdit->ReplaceSelected(aRefStr); + else + pEdit->SetRefString( aRefStr ); updateTitle(); } } |