[Libreoffice-commits] core.git: Branch 'libreoffice-6-2' - vcl/source
Caolán McNamara (via logerrit)
logerrit at kemper.freedesktop.org
Mon Jun 17 13:05:12 UTC 2019
vcl/source/window/builder.cxx | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
New commits:
commit 53a2aeccd6b339bc5b7d7b403723fa48ecc5dd58
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Mon Jun 17 11:53:11 2019 +0100
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Mon Jun 17 15:03:57 2019 +0200
Resolves: tdf#125883 if old and new text will be the same don't change it
that way the cursor and selection is left alone
Change-Id: Id6efa7e2fe27f031761271fd591de7a73a1f6963
Reviewed-on: https://gerrit.libreoffice.org/74160
Reviewed-by: Michael Stahl <Michael.Stahl at cib.de>
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/vcl/source/window/builder.cxx b/vcl/source/window/builder.cxx
index 6f6189d11d57..ea4153161e3c 100644
--- a/vcl/source/window/builder.cxx
+++ b/vcl/source/window/builder.cxx
@@ -181,7 +181,9 @@ namespace weld
IMPL_LINK(MetricSpinButton, spin_button_output, SpinButton&, rSpinButton, void)
{
- rSpinButton.set_text(format_number(rSpinButton.get_value()));
+ OUString sNewText(format_number(rSpinButton.get_value()));
+ if (sNewText != rSpinButton.get_text())
+ rSpinButton.set_text(sNewText);
}
void MetricSpinButton::update_width_chars()
More information about the Libreoffice-commits
mailing list