From bcaeebd98a697d6bcf891990c3b13de5da1790e7 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Fri, 13 Sep 2019 11:19:56 +0100 Subject: Related: tdf#125531 use RemoveTabPage for removing a tab page MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit which removes the tab cross-platform Change-Id: If2584cc75350fb0106f1a1f5190abb74b0ee0ccf Reviewed-on: https://gerrit.libreoffice.org/78871 Tested-by: Jenkins Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara --- sfx2/source/dialog/dinfdlg.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'sfx2/source/dialog') diff --git a/sfx2/source/dialog/dinfdlg.cxx b/sfx2/source/dialog/dinfdlg.cxx index 2b49b18bfc3b..782d4faa0b2e 100644 --- a/sfx2/source/dialog/dinfdlg.cxx +++ b/sfx2/source/dialog/dinfdlg.cxx @@ -1127,13 +1127,13 @@ SfxDocumentInfoDialog::SfxDocumentInfoDialog(weld::Window* pParent, const SfxIte AddTabPage("general", SfxDocumentPage::Create, nullptr); AddTabPage("description", SfxDocumentDescPage::Create, nullptr); AddTabPage("customprops", SfxCustomPropertiesPage::Create, nullptr); - AddTabPage("cmisprops", SfxCmisPropertiesPage::Create, nullptr); - if (!rInfoItem.isCmisDocument()) - m_xTabCtrl->get_page("cmisprops")->hide(); + if (rInfoItem.isCmisDocument()) + AddTabPage("cmisprops", SfxCmisPropertiesPage::Create, nullptr); + else + RemoveTabPage("cmisprops"); AddTabPage("security", SfxSecurityPage::Create, nullptr); } - void SfxDocumentInfoDialog::PageCreated(const OString& rId, SfxTabPage &rPage) { if (rId == "general") -- cgit