summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2017-10-20 12:33:57 +0100
committerCaolán McNamara <caolanm@redhat.com>2017-10-20 12:54:14 +0100
commit2e001b40ad0d19c8db528bb4df739e289163779d (patch)
tree1af9b28afd8d1db9570e3701c14e03fe0d31026d
parent6a902de6db0537df0b7e13df062dc89006f98581 (diff)
Resolves: tdf#113252 missing tabs in basic library organizer
Like SfxTabDialog, as in interim measure throw away the TabPage if its not suitable for reuse Change-Id: If8247ea37dfca42e690716a8b687677e0f73c9a8
-rw-r--r--basctl/source/basicide/moduldlg.cxx7
-rw-r--r--vcl/unx/generic/print/prtsetup.cxx7
2 files changed, 14 insertions, 0 deletions
diff --git a/basctl/source/basicide/moduldlg.cxx b/basctl/source/basicide/moduldlg.cxx
index 47f8b4209f3d..dd5b4697f135 100644
--- a/basctl/source/basicide/moduldlg.cxx
+++ b/basctl/source/basicide/moduldlg.cxx
@@ -458,6 +458,13 @@ OrganizeDialog::OrganizeDialog(vcl::Window* pParent, sal_Int16 tabId,
{
get(m_pTabCtrl, "tabcontrol");
+ sal_uInt16 nPageCount = m_pTabCtrl->GetPageCount();
+ for (sal_uInt16 nPage = 0; nPage < nPageCount; ++nPage)
+ {
+ sal_uInt16 nPageId = m_pTabCtrl->GetPageId(nPage);
+ m_pTabCtrl->SetTabPage(nPageId, nullptr);
+ }
+
m_pTabCtrl->SetActivatePageHdl(LINK(this, OrganizeDialog, ActivatePageHdl));
if( tabId == 0 )
diff --git a/vcl/unx/generic/print/prtsetup.cxx b/vcl/unx/generic/print/prtsetup.cxx
index 35620aa0430b..b4fb58a749d3 100644
--- a/vcl/unx/generic/print/prtsetup.cxx
+++ b/vcl/unx/generic/print/prtsetup.cxx
@@ -83,6 +83,13 @@ RTSDialog::RTSDialog(const PrinterInfo& rJobData, vcl::Window* pParent)
get(m_pCancelButton, "cancel");
get(m_pTabControl, "notebook");
+ sal_uInt16 nPageCount = m_pTabControl->GetPageCount();
+ for (sal_uInt16 nPage = 0; nPage < nPageCount; ++nPage)
+ {
+ sal_uInt16 nPageId = m_pTabControl->GetPageId(nPage);
+ m_pTabControl->SetTabPage(nPageId, nullptr);
+ }
+
OUString aTitle(GetText());
SetText(aTitle.replaceAll("%s", m_aJobData.m_aPrinterName));