svx/source/fmcomp/gridcell.cxx | 6 +++--- svx/source/inc/gridcell.hxx | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-)
New commits: commit ea8e41710045a1e20f6cc1d210f3534c4f5fe9c9 Author: Caolán McNamara <[email protected]> AuthorDate: Fri Oct 1 15:49:45 2021 +0100 Commit: Caolán McNamara <[email protected]> CommitDate: Fri Oct 1 21:34:45 2021 +0200 Related: tdf#141633 use IsMultiLineEdit instead of !IsSimpleEdit seeing as the meaning of not simple is multi line editing instead of something more exotic like more complex formatted text Change-Id: Ic08834eed31b35ce16ba34bbbf8ff111d1a67da0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122952 Tested-by: Jenkins Reviewed-by: Caolán McNamara <[email protected]> diff --git a/svx/source/fmcomp/gridcell.cxx b/svx/source/fmcomp/gridcell.cxx index da5a387ad187..45362a0e7140 100644 --- a/svx/source/fmcomp/gridcell.cxx +++ b/svx/source/fmcomp/gridcell.cxx @@ -1028,7 +1028,7 @@ void DbLimitedLengthField::implSetEffectiveMaxTextLen(sal_Int32 nMaxLen) DbTextField::DbTextField(DbGridColumn& _rColumn) :DbLimitedLengthField(_rColumn) - ,m_bIsSimpleEdit( true ) + ,m_bIsMultiLineEdit(false) { } @@ -1061,7 +1061,7 @@ void DbTextField::Init(BrowserDataWin& rParent, const Reference< XRowSet >& xCur "caught an exception while determining the multi-line capabilities!"); } - m_bIsSimpleEdit = !bIsMultiLine; + m_bIsMultiLineEdit = bIsMultiLine; if ( bIsMultiLine ) { auto xEditControl = VclPtr<MultiLineTextCell>::Create(&rParent); @@ -3627,7 +3627,7 @@ FmXEditCell::FmXEditCell( DbGridColumn* pColumn, std::unique_ptr<DbCellControl> { m_pEditImplementation = pTextField->GetEditImplementation(); - if ( !pTextField->IsSimpleEdit() ) + if (pTextField->IsMultiLineEdit()) m_bFastPaint = false; } else diff --git a/svx/source/inc/gridcell.hxx b/svx/source/inc/gridcell.hxx index ee2ddc061f28..081f7a4bc684 100644 --- a/svx/source/inc/gridcell.hxx +++ b/svx/source/inc/gridcell.hxx @@ -380,7 +380,7 @@ class DbTextField final : public DbLimitedLengthField { std::unique_ptr<::svt::IEditImplementation> m_pEdit; std::unique_ptr<::svt::IEditImplementation> m_pPainterImplementation; - bool m_bIsSimpleEdit; + bool m_bIsMultiLineEdit; virtual ~DbTextField( ) override; @@ -388,7 +388,7 @@ public: DbTextField(DbGridColumn& _rColumn); ::svt::IEditImplementation* GetEditImplementation() { return m_pEdit.get(); } - bool IsSimpleEdit() const { return m_bIsSimpleEdit; } + bool IsMultiLineEdit() const { return m_bIsMultiLineEdit; } virtual void Init( BrowserDataWin& rParent, const css::uno::Reference< css::sdbc::XRowSet >& xCursor ) override; virtual OUString GetFormatText(const css::uno::Reference< css::sdb::XColumn >& _rxField, const css::uno::Reference< css::util::XNumberFormatter >& xFormatter, const Color** ppColor = nullptr) override;
