diff options
author | Michael Stahl <mstahl@redhat.com> | 2011-11-30 16:08:23 +0100 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2011-12-03 00:48:13 +0100 |
commit | db74fdf5346c4f97256522ee2a3200fcdce1af5a (patch) | |
tree | 46f79b6c8d8c37bc3ba3c018bff0919483273373 /sfx2 | |
parent | 4f201dc32b58b56e27fa12b6c770ff38c2da7230 (diff) |
sfx2::DocumentInserter: remove nFlags ctor param
Diffstat (limited to 'sfx2')
-rw-r--r-- | sfx2/inc/sfx2/docinsert.hxx | 6 | ||||
-rw-r--r-- | sfx2/source/doc/docinsert.cxx | 13 |
2 files changed, 9 insertions, 10 deletions
diff --git a/sfx2/inc/sfx2/docinsert.hxx b/sfx2/inc/sfx2/docinsert.hxx index 40969a76dbe1..292b396cc906 100644 --- a/sfx2/inc/sfx2/docinsert.hxx +++ b/sfx2/inc/sfx2/docinsert.hxx @@ -60,8 +60,7 @@ private: String m_sFilter; Link m_aDialogClosedLink; - bool m_bMultiSelectionEnabled; - sal_Int64 m_nDlgFlags; + sal_Int64 const m_nDlgFlags; ErrCode m_nError; sfx2::FileDialogHelper* m_pFileDlg; @@ -71,7 +70,8 @@ private: DECL_LINK( DialogClosedHdl, sfx2::FileDialogHelper* ); public: - DocumentInserter( sal_Int64 _nFlags, const String& _rFactory, bool _bEnableMultiSelection = false ); + DocumentInserter(const String& rFactory, + bool const bEnableMultiSelection = false); ~DocumentInserter(); void StartExecuteModal( const Link& _rDialogClosedLink ); diff --git a/sfx2/source/doc/docinsert.cxx b/sfx2/source/doc/docinsert.cxx index 3eab0a051345..cb4354b1d2d2 100644 --- a/sfx2/source/doc/docinsert.cxx +++ b/sfx2/source/doc/docinsert.cxx @@ -70,11 +70,12 @@ namespace sfx2 { // ======================================================================= DocumentInserter::DocumentInserter( - sal_Int64 _nFlags, const String& _rFactory, bool _bEnableMultiSelection ) : + const String& rFactory, bool const bEnableMultiSelection) : - m_sDocFactory ( _rFactory ) - , m_bMultiSelectionEnabled ( _bEnableMultiSelection ) - , m_nDlgFlags ( _nFlags | SFXWB_INSERT | WB_3DLOOK ) + m_sDocFactory ( rFactory ) + , m_nDlgFlags ( (bEnableMultiSelection) + ? (SFXWB_INSERT|SFXWB_MULTISELECTION) + : SFXWB_INSERT ) , m_nError ( ERRCODE_NONE ) , m_pFileDlg ( NULL ) , m_pItemSet ( NULL ) @@ -95,9 +96,7 @@ void DocumentInserter::StartExecuteModal( const Link& _rDialogClosedLink ) DELETEZ( m_pURLList ); if ( !m_pFileDlg ) { - sal_Int64 nFlags = m_bMultiSelectionEnabled ? ( m_nDlgFlags | SFXWB_MULTISELECTION ) - : m_nDlgFlags; - m_pFileDlg = new FileDialogHelper( nFlags, m_sDocFactory ); + m_pFileDlg = new FileDialogHelper( m_nDlgFlags, m_sDocFactory ); } m_pFileDlg->StartExecuteModal( LINK( this, DocumentInserter, DialogClosedHdl ) ); } |