summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorSamuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>2023-09-04 11:52:08 +0200
committerAdolfo Jayme Barrientos <fitojb@ubuntu.com>2023-10-09 17:20:50 +0200
commitdef6d74f37b2fce8e0f29fb967108dacefd78896 (patch)
treef389a42bd273c4d58f19497f666ea44fcf5cea68 /svx
parent550fae2a94c355356ba002294a1e3df1fcade48b (diff)
tdf#151188 Select correct fill type in sidebar
Change-Id: Ic123e6b21009cc57bf1c4b5f4edc6dcd277bae0a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156510 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de> (cherry picked from commit b5effb66ee1563689c27ff10b682357120ab7786) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156534 Reviewed-by: Patrick Luby <plubius@neooffice.org> Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
Diffstat (limited to 'svx')
-rw-r--r--svx/source/sidebar/area/AreaPropertyPanelBase.cxx10
1 files changed, 7 insertions, 3 deletions
diff --git a/svx/source/sidebar/area/AreaPropertyPanelBase.cxx b/svx/source/sidebar/area/AreaPropertyPanelBase.cxx
index 128709704d3c..fdb5ca82a899 100644
--- a/svx/source/sidebar/area/AreaPropertyPanelBase.cxx
+++ b/svx/source/sidebar/area/AreaPropertyPanelBase.cxx
@@ -1067,10 +1067,14 @@ void AreaPropertyPanelBase::updateFillUseBackground(bool bDisabled, bool bDefaul
if (pState)
{
const XFillUseSlideBackgroundItem* pItem = static_cast<const XFillUseSlideBackgroundItem*>(pState);
- // When XFillUseSlideBackgroundItem is true, select "Use Background Fill". When false, select "None"
+ // When XFillUseSlideBackgroundItem is set, select "Use Background Fill".
+ // When false, select "None" (only if "Use background fill" was selected beforehand)
int nPos = pItem->GetValue() ? USE_BACKGROUND : NONE;
- mxLbFillType->set_active(nPos);
- FillStyleChanged(false);
+ if ((nPos == NONE && mxLbFillType->get_active() == USE_BACKGROUND) || nPos == USE_BACKGROUND)
+ {
+ mxLbFillType->set_active(nPos);
+ FillStyleChanged(false);
+ }
}
}
}