diff options
author | Noel Grandin <noel@peralex.com> | 2013-01-31 18:02:02 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2013-02-11 08:02:18 +0200 |
commit | e7a76a0e65a185c3ac0ef041f7e6957d3f8b655b (patch) | |
tree | 5f3ffccac0b0de52a551075abe31de0f2ce3b9bd /extensions | |
parent | 5d0b2b011ff2f141db452ffef84c3a77efbd6e7b (diff) |
fdo#46808, convert form::runtime::FormController to new-style
Change-Id: Ied761cbb8e23d65596a5fdc4650e1cd2c95e9245
Diffstat (limited to 'extensions')
-rw-r--r-- | extensions/source/bibliography/datman.cxx | 6 | ||||
-rw-r--r-- | extensions/source/propctrlr/eventhandler.cxx | 6 |
2 files changed, 6 insertions, 6 deletions
diff --git a/extensions/source/bibliography/datman.cxx b/extensions/source/bibliography/datman.cxx index 93b42303a0ad..a3667b119941 100644 --- a/extensions/source/bibliography/datman.cxx +++ b/extensions/source/bibliography/datman.cxx @@ -38,6 +38,7 @@ #include <com/sun/star/sdb/XCompletedConnection.hpp> #include <com/sun/star/task/InteractionHandler.hpp> #include <com/sun/star/form/XLoadable.hpp> +#include <com/sun/star/form/runtime/FormController.hpp> #include <com/sun/star/sdbcx/XColumnsSupplier.hpp> #include <com/sun/star/form/XGridColumnFactory.hpp> #include <com/sun/star/io/XDataInputStream.hpp> @@ -1641,9 +1642,8 @@ uno::Reference< form::runtime::XFormController > BibDataManager::GetFormControll { if(!m_xFormCtrl.is()) { - Reference< lang::XMultiServiceFactory > xMgr = comphelper::getProcessServiceFactory(); - m_xFormCtrl = uno::Reference< form::runtime::XFormController > ( - xMgr->createInstance("com.sun.star.form.runtime.FormController"), UNO_QUERY); + Reference< uno::XComponentContext > xContext = comphelper::getProcessComponentContext(); + m_xFormCtrl = form::runtime::FormController::create(xContext); m_xFormCtrl->setModel(uno::Reference< awt::XTabControllerModel > (getForm(), UNO_QUERY)); m_xFormDispatch = uno::Reference< frame::XDispatch > ( m_xFormCtrl, UNO_QUERY); } diff --git a/extensions/source/propctrlr/eventhandler.cxx b/extensions/source/propctrlr/eventhandler.cxx index 73a6016d1407..7e8a02045af3 100644 --- a/extensions/source/propctrlr/eventhandler.cxx +++ b/extensions/source/propctrlr/eventhandler.cxx @@ -41,7 +41,7 @@ #include <com/sun/star/container/XNameReplace.hpp> #include <com/sun/star/form/FormComponentType.hpp> #include <com/sun/star/form/XForm.hpp> -#include <com/sun/star/form/runtime/XFormController.hpp> +#include <com/sun/star/form/runtime/FormController.hpp> #include <com/sun/star/inspection/PropertyControlType.hpp> #include <com/sun/star/lang/NullPointerException.hpp> #include <com/sun/star/script/XEventAttacherManager.hpp> @@ -107,6 +107,7 @@ namespace pcr using ::com::sun::star::container::XNameContainer; using ::com::sun::star::awt::XTabControllerModel; using ::com::sun::star::form::XForm; + using ::com::sun::star::form::runtime::FormController; using ::com::sun::star::form::runtime::XFormController; using ::com::sun::star::beans::UnknownPropertyException; using ::com::sun::star::uno::makeAny; @@ -1110,8 +1111,7 @@ namespace pcr if ( xComponentAsForm.is() ) { Reference< XTabControllerModel > xComponentAsTCModel( m_xComponent, UNO_QUERY_THROW ); - Reference< XFormController > xController( - m_aContext.createComponent( "com.sun.star.form.runtime.FormController" ), UNO_QUERY_THROW ); + Reference< XFormController > xController = FormController::create( m_aContext.getUNOContext() ); xController->setModel( xComponentAsTCModel ); xReturn = xController; |