summaryrefslogtreecommitdiff
path: root/svx/source/tbxctrls
diff options
context:
space:
mode:
authorMert Tumer <mert.tumer@collabora.com>2022-01-18 12:57:16 +0300
committerAndras Timar <andras.timar@collabora.com>2022-02-21 22:01:34 +0100
commit0a31e12cbb878549683da798ffd0b57197bdcf29 (patch)
treeb682525a5ca18c0e30f0103d219309e6f2598135 /svx/source/tbxctrls
parent79d3c5675dc52742997ce60bb1d6b6d5ccaa0fd3 (diff)
set active element to -1 when no selection for fontnamebox
FontNameBox sets the currentVal to emptystring when there's a mixed font-name selection on the text but does not update the active_element which is incorrect whereas other comboboxes such as FontSize does it correctly. Signed-off-by: Mert Tumer <mert.tumer@collabora.com> Change-Id: Iff86bba64c2ab564ff5c5fa979eb846af9651a11 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128551 Reviewed-by: Szymon Kłos <szymon.klos@collabora.com> Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Diffstat (limited to 'svx/source/tbxctrls')
-rw-r--r--svx/source/tbxctrls/tbcontrl.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/svx/source/tbxctrls/tbcontrl.cxx b/svx/source/tbxctrls/tbcontrl.cxx
index 2946bea56c21..465b96c13106 100644
--- a/svx/source/tbxctrls/tbcontrl.cxx
+++ b/svx/source/tbxctrls/tbcontrl.cxx
@@ -3099,8 +3099,11 @@ void SvxFontNameBox_Base::statusChanged_Impl( const css::frame::FeatureStateEven
css::awt::FontDescriptor aFontDesc;
if ( rEvent.State >>= aFontDesc )
Update(&aFontDesc);
- else
+ else {
+ // no active element; delete value in the display
+ m_xWidget->set_active(-1);
set_active_or_entry_text("");
+ }
m_xWidget->save_value();
}
}