tdf#125330 Disable Filter and Change Table buttons

in the Select Address List dialog if there are no entries

Change-Id: Iaff60bd0e031884bf1032cf656260353f48ce60d
Reviewed-on: https://gerrit.libreoffice.org/77025
Tested-by: Jenkins
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
This commit is contained in:
Kelemen Gábor
2019-08-06 14:22:36 +02:00
committed by László Németh
parent 2340c2ffe4
commit a9e098aa4e

View File

@@ -211,6 +211,8 @@ SwAddressListDialog::SwAddressListDialog(SwMailMergeAddressBlockPage* pParent)
m_xOK->set_sensitive(m_xListLB->n_children() > 0 && bEnableOK);
m_xEditPB->set_sensitive(bEnableEdit);
m_xRemovePB->set_sensitive(m_xListLB->n_children() > 0);
m_xFilterPB->set_sensitive(m_xListLB->n_children() > 0);
m_xTablePB->set_sensitive(m_xListLB->n_children() > 0);
m_xListLB->connect_changed(LINK(this, SwAddressListDialog, ListBoxSelectHdl_Impl));
TableSelectHdl(nullptr);
}
@@ -307,6 +309,7 @@ IMPL_LINK_NOARG(SwAddressListDialog, RemoveHdl_Impl, weld::Button&, void)
{
m_xRemovePB->set_sensitive(false);
m_xEditPB->set_sensitive(false);
m_xFilterPB->set_sensitive(false);
m_xCreateListPB->set_sensitive(true);
}
}