diff options
Diffstat (limited to 'svx/source')
-rw-r--r-- | svx/source/fmcomp/fmgridcl.cxx | 8 | ||||
-rw-r--r-- | svx/source/fmcomp/fmgridif.cxx | 18 | ||||
-rw-r--r-- | svx/source/fmcomp/gridcell.cxx | 4 | ||||
-rw-r--r-- | svx/source/fmcomp/gridctrl.cxx | 6 |
4 files changed, 18 insertions, 18 deletions
diff --git a/svx/source/fmcomp/fmgridcl.cxx b/svx/source/fmcomp/fmgridcl.cxx index b3c259deda8b..a864db34a1c2 100644 --- a/svx/source/fmcomp/fmgridcl.cxx +++ b/svx/source/fmcomp/fmgridcl.cxx @@ -285,8 +285,8 @@ sal_Int8 FmGridHeader::ExecuteDrop( const ExecuteDropEvent& _rEvt ) try { OUString sSignificantSource( sDatasouce.isEmpty() ? sDatabaseLocation : sDatasouce ); - xConnection = OStaticDataAccessTools().getConnection_withFeedback(sSignificantSource, OUString(),OUString(), - comphelper::getComponentContext( static_cast<FmGridControl*>(GetParent())->getServiceManager() )); + xConnection = OStaticDataAccessTools().getConnection_withFeedback(sSignificantSource, OUString(), OUString(), + static_cast<FmGridControl*>(GetParent())->getContext() ); } catch(NoSuchElementException&) { // allowed, means sDatasouce isn't a valid data source name .... @@ -1017,11 +1017,11 @@ void FmGridHeader::Command(const CommandEvent& rEvt) //------------------------------------------------------------------------------ FmGridControl::FmGridControl( - Reference< ::com::sun::star::lang::XMultiServiceFactory > _rxFactory, + const Reference< ::com::sun::star::uno::XComponentContext >& _rxContext, Window* pParent, FmXGridPeer* _pPeer, WinBits nBits) - :DbGridControl(_rxFactory, pParent, nBits) + :DbGridControl(_rxContext, pParent, nBits) ,m_pPeer(_pPeer) ,m_nCurrentSelectedColumn(-1) ,m_nMarkedColumnId(BROWSER_INVALIDID) diff --git a/svx/source/fmcomp/fmgridif.cxx b/svx/source/fmcomp/fmgridif.cxx index d202afc15b8a..53781d2c04fc 100644 --- a/svx/source/fmcomp/fmgridif.cxx +++ b/svx/source/fmcomp/fmgridif.cxx @@ -351,11 +351,11 @@ void SAL_CALL FmXGridControlMultiplexer::columnChanged( const EventObject& _even //------------------------------------------------------------------ Reference< XInterface > SAL_CALL FmXGridControl_NewInstance_Impl(const Reference< XMultiServiceFactory>& _rxFactory) { - return *(new FmXGridControl(_rxFactory)); + return *(new FmXGridControl( comphelper::getComponentContext(_rxFactory) )); } DBG_NAME(FmXGridControl ) //------------------------------------------------------------------------------ -FmXGridControl::FmXGridControl(const Reference< XMultiServiceFactory >& _rxFactory) +FmXGridControl::FmXGridControl(const Reference< XComponentContext >& _rxContext) :UnoControl() ,m_aModifyListeners(*this, GetMutex()) ,m_aUpdateListeners(*this, GetMutex()) @@ -364,7 +364,7 @@ FmXGridControl::FmXGridControl(const Reference< XMultiServiceFactory >& _rxFacto ,m_aGridControlListeners(*this, GetMutex()) ,m_nPeerCreationLevel(0) ,m_bInDraw(sal_False) - ,m_xServiceFactory(_rxFactory) + ,m_xContext(_rxContext) { DBG_CTOR(FmXGridControl ,NULL); } @@ -475,7 +475,7 @@ sal_Bool SAL_CALL FmXGridControl::setModel(const Reference< ::com::sun::star::aw //------------------------------------------------------------------------------ FmXGridPeer* FmXGridControl::imp_CreatePeer(Window* pParent) { - FmXGridPeer* pReturn = new FmXGridPeer(m_xServiceFactory); + FmXGridPeer* pReturn = new FmXGridPeer(m_xContext); // translate properties into WinBits WinBits nStyle = WB_TABSTOP; @@ -1057,7 +1057,7 @@ void FmXGridPeer::GridListenerDelegator::columnChanged() //------------------------------------------------------------------ Reference< XInterface > FmXGridPeer_CreateInstance(const Reference< XMultiServiceFactory>& _rxFactory) { - FmXGridPeer* pNewObject = new FmXGridPeer(_rxFactory); + FmXGridPeer* pNewObject = new FmXGridPeer( comphelper::getComponentContext(_rxFactory) ); pNewObject->Create(NULL, WB_TABSTOP); return *pNewObject; } @@ -1122,7 +1122,7 @@ namespace fmgridif using namespace fmgridif; //------------------------------------------------------------------ -FmXGridPeer::FmXGridPeer(const Reference< XMultiServiceFactory >& _rxFactory) +FmXGridPeer::FmXGridPeer(const Reference< XComponentContext >& _rxContext) :m_aModifyListeners(m_aMutex) ,m_aUpdateListeners(m_aMutex) ,m_aContainerListeners(m_aMutex) @@ -1134,7 +1134,7 @@ FmXGridPeer::FmXGridPeer(const Reference< XMultiServiceFactory >& _rxFactory) ,m_pStateCache(NULL) ,m_pDispatchers(NULL) ,m_pGridListener(NULL) - ,m_xServiceFactory(_rxFactory) + ,m_xContext(_rxContext) { // Create must be called after this constructure m_pGridListener = new GridListenerDelegator( this ); @@ -1143,7 +1143,7 @@ FmXGridPeer::FmXGridPeer(const Reference< XMultiServiceFactory >& _rxFactory) //------------------------------------------------------------------------------ FmGridControl* FmXGridPeer::imp_CreateControl(Window* pParent, WinBits nStyle) { - return new FmGridControl(m_xServiceFactory, pParent, this, nStyle); + return new FmGridControl(m_xContext, pParent, this, nStyle); } //------------------------------------------------------------------------------ @@ -1826,7 +1826,7 @@ void FmXGridPeer::elementInserted(const ContainerEvent& evt) throw( RuntimeExcep if (::comphelper::getBOOL(aHidden)) pGrid->HideColumn(pCol->GetId()); - FormControlFactory( m_xServiceFactory ).initializeTextFieldLineEnds( xNewColumn ); + FormControlFactory( m_xContext ).initializeTextFieldLineEnds( xNewColumn ); } //------------------------------------------------------------------------------ diff --git a/svx/source/fmcomp/gridcell.cxx b/svx/source/fmcomp/gridcell.cxx index dae1f8ddd0f7..f7dcf1144d1b 100644 --- a/svx/source/fmcomp/gridcell.cxx +++ b/svx/source/fmcomp/gridcell.cxx @@ -178,7 +178,7 @@ void DbGridColumn::CreateControl(sal_Int32 _nFieldPos, const Reference< ::com::s DbCellControl* pCellControl = NULL; if (m_rParent.IsFilterMode()) { - pCellControl = new DbFilterField(comphelper::getComponentContext(m_rParent.getServiceManager()),*this); + pCellControl = new DbFilterField(m_rParent.getContext(),*this); } else { @@ -191,7 +191,7 @@ void DbGridColumn::CreateControl(sal_Int32 _nFieldPos, const Reference< ::com::s case TYPE_DATEFIELD: pCellControl = new DbDateField(*this); break; case TYPE_LISTBOX: pCellControl = new DbListBox(*this); break; case TYPE_NUMERICFIELD: pCellControl = new DbNumericField(*this); break; - case TYPE_PATTERNFIELD: pCellControl = new DbPatternField( *this, ::comphelper::ComponentContext( m_rParent.getServiceManager() ) ); break; + case TYPE_PATTERNFIELD: pCellControl = new DbPatternField( *this, m_rParent.getContext() ); break; case TYPE_TEXTFIELD: pCellControl = new DbTextField(*this); break; case TYPE_TIMEFIELD: pCellControl = new DbTimeField(*this); break; case TYPE_FORMATTEDFIELD: pCellControl = new DbFormattedField(*this); break; diff --git a/svx/source/fmcomp/gridctrl.cxx b/svx/source/fmcomp/gridctrl.cxx index 64bf73436454..83358a73284c 100644 --- a/svx/source/fmcomp/gridctrl.cxx +++ b/svx/source/fmcomp/gridctrl.cxx @@ -904,11 +904,11 @@ void DbGridRow::SetState(CursorWrapper* pCur, sal_Bool bPaintCursor) DBG_NAME(DbGridControl); //------------------------------------------------------------------------------ DbGridControl::DbGridControl( - Reference< XMultiServiceFactory > _rxFactory, + Reference< XComponentContext > _rxContext, Window* pParent, WinBits nBits) :DbGridControl_Base(pParent, EBBF_NONE, nBits, DEFAULT_BROWSE_MODE ) - ,m_xServiceFactory(_rxFactory) + ,m_xContext(_rxContext) ,m_aBar(this) ,m_nAsynAdjustEvent(0) ,m_pDataSourcePropMultiplexer(NULL) @@ -1448,7 +1448,7 @@ void DbGridControl::setDataSource(const Reference< XRowSet >& _xCursor, sal_uInt if (xSupplier.is()) { m_xFormatter = Reference< ::com::sun::star::util::XNumberFormatter >( - ::com::sun::star::util::NumberFormatter::create(comphelper::getComponentContext(m_xServiceFactory)), + ::com::sun::star::util::NumberFormatter::create(m_xContext), UNO_QUERY); m_xFormatter->attachNumberFormatsSupplier(xSupplier); |