sw/source/ui/dialog/uiregionsw.cxx | 16 ++++++++++++++++ 1 file changed, 16 insertions(+)
New commits: commit 6f56317244af98cae66260dd7e75920f68666782 Author: Andras Timar <andras.ti...@collabora.com> AuthorDate: Thu Nov 24 13:37:36 2022 +0100 Commit: Henry Castro <hcas...@collabora.com> CommitDate: Mon Dec 5 12:49:04 2022 +0000 Disallow linking files as Writer sections in Online Change-Id: I9e4971c72db44ca8216ac468240dd52d46e0b680 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/143225 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoff...@gmail.com> Reviewed-by: Henry Castro <hcas...@collabora.com> diff --git a/sw/source/ui/dialog/uiregionsw.cxx b/sw/source/ui/dialog/uiregionsw.cxx index 9ff77c893263..94ed8bf40a8e 100644 --- a/sw/source/ui/dialog/uiregionsw.cxx +++ b/sw/source/ui/dialog/uiregionsw.cxx @@ -35,6 +35,7 @@ #include <editeng/sizeitem.hxx> #include <svtools/htmlcfg.hxx> #include <osl/diagnose.h> +#include <comphelper/lok.hxx> #include <uitool.hxx> #include <IMark.hxx> @@ -1477,6 +1478,21 @@ SwInsertSectionTabPage::SwInsertSectionTabPage(weld::Container* pPage, weld::Dia m_xDDECB->connect_toggled( LINK( this, SwInsertSectionTabPage, DDEHdl )); ChangeProtectHdl(*m_xProtectCB); m_xSubRegionED->set_entry_completion(true, true); + + // Hide Link section. In general it makes no sense to insert a file from the jail, + // because it does not contain any usable files (documents). + if(comphelper::LibreOfficeKit::isActive()) + { + m_xBuilder->weld_label("label1")->hide(); // Link + m_xFileCB->hide(); + m_xDDECB->hide(); + m_xDDECommandFT->hide(); + m_xFileNameFT->hide(); + m_xFileNameED->hide(); + m_xFilePB->hide(); + m_xSubRegionFT->hide(); + m_xSubRegionED->hide(); + } } SwInsertSectionTabPage::~SwInsertSectionTabPage()