sd: Drop always false TableDesignWidget::m_bModal

The member is initialized to false in the ctor
and that value is never changed afterwards.
Drop it altogether and simplify code accordingly.

Change-Id: I0213e9f74b353a214af3ad163a934bfa7e868412
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211913
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins
This commit is contained in:
Michael Weghorn
2026-10-07 20:27:00 +02:00
parent 294f872019
commit 09d3cc2c14
2 changed files with 7 additions and 15 deletions
-1
View File
@@ -54,7 +54,6 @@ enum TableCheckBox : sal_uInt16
class TableValueSet final : public ValueSet
{
private:
bool m_bModal;
Link<const Point*, void> maContextMenuHandler;
public:
TableValueSet(std::unique_ptr<weld::ScrolledWindow> pScrolledWindow);
+2 -9
View File
@@ -621,20 +621,16 @@ void TableValueSet::Resize()
SetColCount (static_cast<sal_uInt16>(nColumnCount));
SetLineCount (static_cast<sal_uInt16>(nVisibleRowCount));
if( !m_bModal )
{
WinBits nStyle = GetStyle() & ~WB_VSCROLL;
if( nRowCount > nVisibleRowCount )
if (nRowCount > nVisibleRowCount)
{
nStyle |= WB_VSCROLL;
}
SetStyle( nStyle );
}
SetStyle(nStyle);
}
TableValueSet::TableValueSet(std::unique_ptr<weld::ScrolledWindow> pScrolledWindow)
: ValueSet(std::move(pScrolledWindow))
, m_bModal(false)
{
}
@@ -645,12 +641,9 @@ void TableValueSet::StyleUpdated()
void TableValueSet::updateSettings()
{
if( !m_bModal )
{
Color aColor = Application::GetSettings().GetStyleSettings().GetWindowColor();
SetColor(aColor);
SetExtraSpacing(8);
}
}
void TableDesignWidget::updateControls()