[Libreoffice-commits] core.git: cui/source
Caolán McNamara (via logerrit)
logerrit at kemper.freedesktop.org
Sun Apr 28 20:31:47 UTC 2019
cui/source/inc/tabstpge.hxx | 4 ++--
cui/source/tabpages/tabstpge.cxx | 30 ++++++++++++++++++------------
2 files changed, 20 insertions(+), 14 deletions(-)
New commits:
commit 7d69b4da74a6e826357392ade2fc3175d3092f87
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Sun Apr 28 17:16:36 2019 +0100
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Sun Apr 28 22:31:06 2019 +0200
Resolves: tdf#125002 toggling on radio button generates click on another
so use toggle and ignore toggle offs
Change-Id: Id6a9f3a7a9cf02d62ede00e4c246629406f9a64b
Reviewed-on: https://gerrit.libreoffice.org/71481
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/cui/source/inc/tabstpge.hxx b/cui/source/inc/tabstpge.hxx
index 949877077bd2..a0c8e7ce7b5d 100644
--- a/cui/source/inc/tabstpge.hxx
+++ b/cui/source/inc/tabstpge.hxx
@@ -133,8 +133,8 @@ private:
DECL_LINK(DelHdl_Impl, weld::Button&, void);
DECL_LINK(DelAllHdl_Impl, weld::Button&, void);
- DECL_LINK(FillTypeCheckHdl_Impl, weld::Button&, void);
- DECL_LINK(TabTypeCheckHdl_Impl, weld::Button&, void);
+ DECL_LINK(FillTypeCheckHdl_Impl, weld::ToggleButton&, void);
+ DECL_LINK(TabTypeCheckHdl_Impl, weld::ToggleButton&, void);
DECL_LINK(SelectHdl_Impl, weld::TreeView&, void);
DECL_LINK(ModifyHdl_Impl, weld::ComboBox&, void);
diff --git a/cui/source/tabpages/tabstpge.cxx b/cui/source/tabpages/tabstpge.cxx
index a942287b1070..12939d618a3d 100644
--- a/cui/source/tabpages/tabstpge.cxx
+++ b/cui/source/tabpages/tabstpge.cxx
@@ -116,22 +116,22 @@ SvxTabulatorTabPage::SvxTabulatorTabPage(TabPageParent pParent, const SfxItemSet
m_xDelBtn->connect_clicked(LINK(this,SvxTabulatorTabPage, DelHdl_Impl));
m_xDelAllBtn->connect_clicked(LINK(this,SvxTabulatorTabPage, DelAllHdl_Impl));
- Link<weld::Button&,void> aLink = LINK(this, SvxTabulatorTabPage, TabTypeCheckHdl_Impl);
- m_xLeftTab->connect_clicked(aLink);
- m_xRightTab->connect_clicked(aLink);
- m_xDezTab->connect_clicked(aLink);
- m_xCenterTab->connect_clicked(aLink);
+ Link<weld::ToggleButton&,void> aLink = LINK(this, SvxTabulatorTabPage, TabTypeCheckHdl_Impl);
+ m_xLeftTab->connect_toggled(aLink);
+ m_xRightTab->connect_toggled(aLink);
+ m_xDezTab->connect_toggled(aLink);
+ m_xCenterTab->connect_toggled(aLink);
m_xDezChar->connect_focus_out(LINK(this, SvxTabulatorTabPage, GetDezCharHdl_Impl));
m_xDezChar->set_sensitive(false);
m_xDezCharLabel->set_sensitive(false);
aLink = LINK(this, SvxTabulatorTabPage, FillTypeCheckHdl_Impl);
- m_xNoFillChar->connect_clicked(aLink);
- m_xFillPoints->connect_clicked(aLink);
- m_xFillDashLine->connect_clicked(aLink);
- m_xFillSolidLine->connect_clicked(aLink);
- m_xFillSpecial->connect_clicked(aLink);
+ m_xNoFillChar->connect_toggled(aLink);
+ m_xFillPoints->connect_toggled(aLink);
+ m_xFillDashLine->connect_toggled(aLink);
+ m_xFillSolidLine->connect_toggled(aLink);
+ m_xFillSpecial->connect_toggled(aLink);
m_xFillChar->connect_focus_out(LINK(this, SvxTabulatorTabPage, GetFillCharHdl_Impl));
m_xFillChar->set_sensitive(false);
@@ -535,8 +535,11 @@ IMPL_LINK_NOARG(SvxTabulatorTabPage, DelAllHdl_Impl, weld::Button&, void)
}
}
-IMPL_LINK(SvxTabulatorTabPage, TabTypeCheckHdl_Impl, weld::Button&, rBox, void)
+IMPL_LINK(SvxTabulatorTabPage, TabTypeCheckHdl_Impl, weld::ToggleButton&, rBox, void)
{
+ if (!rBox.get_active())
+ return;
+
SvxTabAdjust eAdj;
m_xDezChar->set_sensitive(false);
m_xDezCharLabel->set_sensitive(false);
@@ -565,8 +568,11 @@ IMPL_LINK(SvxTabulatorTabPage, TabTypeCheckHdl_Impl, weld::Button&, rBox, void)
}
}
-IMPL_LINK(SvxTabulatorTabPage, FillTypeCheckHdl_Impl, weld::Button&, rBox, void)
+IMPL_LINK(SvxTabulatorTabPage, FillTypeCheckHdl_Impl, weld::ToggleButton&, rBox, void)
{
+ if (!rBox.get_active())
+ return;
+
sal_uInt8 cFill = ' ';
m_xFillChar->set_text( "" );
m_xFillChar->set_sensitive(false);
More information about the Libreoffice-commits
mailing list