include/vcl/button.hxx | 2 +- vcl/source/control/button.cxx | 8 ++------ 2 files changed, 3 insertions(+), 7 deletions(-)
New commits: commit 425b318a07beda8c0762048dfe96216f099c3936 Author: Justin Luth <justin.l...@collabora.com> AuthorDate: Sat May 30 10:47:12 2020 +0300 Commit: Samuel Mehrbrodt <samuel.mehrbr...@allotropia.de> CommitDate: Thu Mar 16 16:38:19 2023 +0100 Revert "tdf#125609 c10 vcl/button: enforce only one radio selected on init" This has already been reverted in 6.4.5 with commit 64d7f805616fd781d87b49156860d96f081a5a45. I want to get out of this completely, because everything keeps on breaking based on my earlier patches. This reverts commit d35171456bc230efdaa9426da1398b2db7fa0df8, and the accompanying LO 6.4 commit a9f4913f283d34c610c4b73c755fdc828857bfce "tdf#125609 c14: vcl button: don't modify style directly" These reverted supporting commits are obsolete. (They fixed a situation caused by a commit that has since been fully reverted. I left these in for the benefit of anyone who might attempt that initial fix in the future. But now I want to get my finger prints out of here completely.) Change-Id: I0d765ce0cc4ab2b9d282d36a239518d43d6015ee Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95190 Tested-by: Jenkins Reviewed-by: Justin Luth <justin_l...@sil.org> Reviewed-by: Caolán McNamara <caol...@redhat.com> (cherry picked from commit b9c79a4dd4ad58156b60c2e387c0838ba911ab14) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95312 (cherry picked from commit 766be0a8f2f5abec29709ef7317d8a0140fda70d) diff --git a/include/vcl/button.hxx b/include/vcl/button.hxx index 4e782aa7a437..2a63e47a8c9b 100644 --- a/include/vcl/button.hxx +++ b/include/vcl/button.hxx @@ -297,7 +297,7 @@ private: const Size& rImageSize, tools::Rectangle& rStateRect, tools::Rectangle& rMouseRect ); SAL_DLLPRIVATE void ImplDrawRadioButton(vcl::RenderContext& rRenderContext ); - SAL_DLLPRIVATE void ImplUncheckAllOther( const bool bSetStyle = true); + SAL_DLLPRIVATE void ImplUncheckAllOther(); SAL_DLLPRIVATE Size ImplGetRadioImageSize() const; SAL_DLLPRIVATE long ImplGetImageToTextDistance() const; diff --git a/vcl/source/control/button.cxx b/vcl/source/control/button.cxx index b3e33a6c4203..b607a70cddaf 100644 --- a/vcl/source/control/button.cxx +++ b/vcl/source/control/button.cxx @@ -1857,9 +1857,6 @@ WinBits RadioButton::ImplInitStyle( const vcl::Window* pPrevWindow, WinBits nSty nStyle &= ~WB_TABSTOP; } - if ( IsChecked() && IsRadioCheckEnabled() ) - ImplUncheckAllOther( /*bSetStyle=*/false ); - return nStyle; } @@ -2245,10 +2242,9 @@ std::vector< VclPtr<RadioButton> > RadioButton::GetRadioButtonGroup(bool bInclud return aGroup; } -void RadioButton::ImplUncheckAllOther( const bool bSetStyle ) +void RadioButton::ImplUncheckAllOther() { - if ( bSetStyle ) - mpWindowImpl->mnStyle |= WB_TABSTOP; + mpWindowImpl->mnStyle |= WB_TABSTOP; std::vector<VclPtr<RadioButton> > aGroup(GetRadioButtonGroup(false)); // iterate over radio button group and checked buttons