sc/source/ui/attrdlg/attrdlg.cxx | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)
New commits: commit feda414f8b70f50a9f6745d2ce8828316d4711cd Author: Pranam Lashkari <lpra...@collabora.com> AuthorDate: Fri Feb 24 22:20:11 2023 +0530 Commit: Pranam Lashkari <lpra...@collabora.com> CommitDate: Sat Mar 4 01:26:35 2023 +0000 sc: remove protect cell tab from cell format dialog Change-Id: I33a32ca756263426abb4dcb733139baf58221554 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147897 Tested-by: Jenkins Reviewed-by: Pranam Lashkari <lpra...@collabora.com> diff --git a/sc/source/ui/attrdlg/attrdlg.cxx b/sc/source/ui/attrdlg/attrdlg.cxx index 734ae94d606f..4e13eae6dea4 100644 --- a/sc/source/ui/attrdlg/attrdlg.cxx +++ b/sc/source/ui/attrdlg/attrdlg.cxx @@ -30,6 +30,7 @@ #include <editeng/editids.hrc> #include <editeng/flstitem.hxx> #include <osl/diagnose.h> +#include <comphelper/lok.hxx> ScAttrDlg::ScAttrDlg(weld::Window* pParent, const SfxItemSet* pCellAttrs) : SfxTabDialogController(pParent, "modules/scalc/ui/formatcellsdialog.ui", @@ -57,7 +58,11 @@ ScAttrDlg::ScAttrDlg(weld::Window* pParent, const SfxItemSet* pCellAttrs) AddTabPage( "borders", pFact->GetTabPageCreatorFunc( RID_SVXPAGE_BORDER ), nullptr ); OSL_ENSURE(pFact->GetTabPageCreatorFunc( RID_SVXPAGE_BKG ), "GetTabPageCreatorFunc fail!"); AddTabPage( "background", pFact->GetTabPageCreatorFunc( RID_SVXPAGE_BKG ), nullptr ); - AddTabPage( "cellprotection" , ScTabPageProtection::Create, nullptr ); + + if (!comphelper::LibreOfficeKit::isActive()) + AddTabPage( "cellprotection" , ScTabPageProtection::Create, nullptr ); + else + RemoveTabPage( "cellprotection" ); } ScAttrDlg::~ScAttrDlg()