summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2019-04-08 12:32:19 +0100
committerCaolán McNamara <caolanm@redhat.com>2019-04-08 22:24:04 +0200
commit623d7a94a57860b0b227e6ebad6d0d3fcaf11333 (patch)
tree9f21f4240a44e2247aa8d56c2a6e057c4f99e115 /sfx2
parent319c0b2433bb8dd405ed1630dd464ed2b11afefb (diff)
drop newly unused SfxSingleTabDialog
Change-Id: I3b445aba89ce62d7890d387a962f12a7055dc7b4 Reviewed-on: https://gerrit.libreoffice.org/70416 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/dialog/basedlgs.cxx127
1 files changed, 0 insertions, 127 deletions
diff --git a/sfx2/source/dialog/basedlgs.cxx b/sfx2/source/dialog/basedlgs.cxx
index aed00aa2042a..f6f3e1b5a46a 100644
--- a/sfx2/source/dialog/basedlgs.cxx
+++ b/sfx2/source/dialog/basedlgs.cxx
@@ -709,133 +709,6 @@ void SfxFloatingWindow::FillInfo(SfxChildWinInfo& rInfo) const
rInfo.nFlags |= SfxChildWindowFlags::ZOOMIN;
}
-// SfxSingleTabDialog ----------------------------------------------------
-
-IMPL_LINK_NOARG(SfxSingleTabDialog, OKHdl_Impl, Button*, void)
-
-/* [Description]
-
- Ok_Handler; FillItemSet() is called for setting of Page.
-*/
-
-{
- if ( !GetInputItemSet() )
- {
- // TabPage without ItemSet
- EndDialog( RET_OK );
- return;
- }
-
- if ( !GetOutputItemSet() )
- {
- CreateOutputItemSet( *GetInputItemSet() );
- }
- bool bModified = false;
-
- if ( pImpl->m_pSfxPage->HasExchangeSupport() )
- {
- DeactivateRC nRet = pImpl->m_pSfxPage->DeactivatePage( GetOutputSetImpl() );
- if ( nRet != DeactivateRC::LeavePage )
- return;
- else
- bModified = ( GetOutputItemSet()->Count() > 0 );
- }
- else
- bModified = pImpl->m_pSfxPage->FillItemSet( GetOutputSetImpl() );
-
- if ( bModified )
- {
- // Save user data in IniManager.
- pImpl->m_pSfxPage->FillUserData();
- OUString sData( pImpl->m_pSfxPage->GetUserData() );
-
- OUString sConfigId = OStringToOUString(pImpl->m_pSfxPage->GetConfigId(),
- RTL_TEXTENCODING_UTF8);
- SvtViewOptions aPageOpt(EViewType::TabPage, sConfigId);
- aPageOpt.SetUserItem( USERITEM_NAME, makeAny( sData ) );
- EndDialog( RET_OK );
- }
- else
- EndDialog();
-}
-
-
-SfxSingleTabDialog::SfxSingleTabDialog(vcl::Window *pParent, const SfxItemSet& rSet,
- const OUString& rID, const OUString& rUIXMLDescription)
- : SfxModalDialog(pParent, rID, rUIXMLDescription)
- , pImpl(new SingleTabDlgImpl)
-{
- get(pOKBtn, "ok");
- pOKBtn->SetClickHdl( LINK( this, SfxSingleTabDialog, OKHdl_Impl ) );
- get(pCancelBtn, "cancel");
- get(pHelpBtn, "help");
- SetInputSet( &rSet );
-}
-
-SfxSingleTabDialog::SfxSingleTabDialog(vcl::Window* pParent, const SfxItemSet* pInSet,
- const OUString& rID, const OUString& rUIXMLDescription)
- : SfxModalDialog(pParent, rID, rUIXMLDescription)
- , pImpl(new SingleTabDlgImpl)
-{
- get(pOKBtn, "ok");
- pOKBtn->SetClickHdl( LINK( this, SfxSingleTabDialog, OKHdl_Impl ) );
- get(pCancelBtn, "cancel");
- get(pHelpBtn, "help");
- SetInputSet( pInSet );
-}
-
-SfxSingleTabDialog::~SfxSingleTabDialog()
-{
- disposeOnce();
-}
-
-void SfxSingleTabDialog::dispose()
-{
- pImpl->m_pSfxPage.disposeAndClear();
- pImpl.reset();
- pOKBtn.clear();
- pCancelBtn.clear();
- pHelpBtn.clear();
- SfxModalDialog::dispose();
-}
-
-/* [Description]
-
- Insert a (new) TabPage; an existing page is deleted.
- The passed on page is initialized with the initially given Itemset
- through calling Reset().
-*/
-void SfxSingleTabDialog::SetTabPage(SfxTabPage* pTabPage)
-{
- pImpl->m_pSfxPage.disposeAndClear();
- pImpl->m_pSfxPage = pTabPage;
-
- if ( !pImpl->m_pSfxPage )
- return;
-
- // First obtain the user data, only then Reset()
- OUString sConfigId = OStringToOUString(pImpl->m_pSfxPage->GetConfigId(), RTL_TEXTENCODING_UTF8);
- SvtViewOptions aPageOpt(EViewType::TabPage, sConfigId);
- Any aUserItem = aPageOpt.GetUserItem( USERITEM_NAME );
- OUString sUserData;
- aUserItem >>= sUserData;
- pImpl->m_pSfxPage->SetUserData(sUserData);
- pImpl->m_pSfxPage->Reset( GetInputItemSet() );
- pImpl->m_pSfxPage->Show();
-
- pHelpBtn->Show(Help::IsContextHelpEnabled());
-
- // Set TabPage text in the Dialog if there is any
- OUString sTitle(pImpl->m_pSfxPage->GetText());
- if (!sTitle.isEmpty())
- SetText(sTitle);
-
- // Dialog receives the HelpId of TabPage if there is any
- OString sHelpId(pImpl->m_pSfxPage->GetHelpId());
- if (!sHelpId.isEmpty())
- SetHelpId(sHelpId);
-}
-
SfxDialogController::SfxDialogController(weld::Widget* pParent, const OUString& rUIFile,
const OString& rDialogId)
: GenericDialogController(pParent, rUIFile, rDialogId)