summaryrefslogtreecommitdiff
path: root/dbaccess/source/filter/xml/dbloader2.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'dbaccess/source/filter/xml/dbloader2.cxx')
-rw-r--r--dbaccess/source/filter/xml/dbloader2.cxx18
1 files changed, 8 insertions, 10 deletions
diff --git a/dbaccess/source/filter/xml/dbloader2.cxx b/dbaccess/source/filter/xml/dbloader2.cxx
index 7c2efad43a33..7b10bf2b523f 100644
--- a/dbaccess/source/filter/xml/dbloader2.cxx
+++ b/dbaccess/source/filter/xml/dbloader2.cxx
@@ -52,8 +52,9 @@
#include <cppuhelper/implbase.hxx>
#include <cppuhelper/supportsservice.hxx>
#include <sfx2/docfile.hxx>
+#include <unotools/fcm.hxx>
#include <unotools/moduleoptions.hxx>
-#include <tools/diagnose_ex.h>
+#include <comphelper/diagnose_ex.hxx>
#include <vcl/svapp.hxx>
using namespace ::ucbhelper;
@@ -138,8 +139,8 @@ OUString SAL_CALL DBTypeDetection::detect( css::uno::Sequence< css::beans::Prope
{
// After fixing of the i88522 issue ( use the new file locking for database files ) the stream from the type detection can be used further
// for now the file should be reopened to have read/write access
- aMedia.remove( OUString( "InputStream" ) );
- aMedia.remove( OUString( "Stream" ) );
+ aMedia.remove( "InputStream" );
+ aMedia.remove( "Stream" );
aMedia >>= Descriptor;
try
{
@@ -374,7 +375,7 @@ void SAL_CALL DBContentLoader::load(const Reference< XFrame > & rFrame, const OU
else
{
::comphelper::NamedValueCollection aCreationArgs;
- aCreationArgs.put( OUString(INFO_POOLURL), sSalvagedURL );
+ aCreationArgs.put( INFO_POOLURL, sSalvagedURL );
xDocumentDataSource.set( xDatabaseContext->createInstanceWithArguments( aCreationArgs.getWrappedNamedValues() ), UNO_QUERY_THROW );
}
@@ -447,11 +448,8 @@ void SAL_CALL DBContentLoader::load(const Reference< XFrame > & rFrame, const OU
Reference< XModel2 > xModel2( xModel, UNO_QUERY_THROW );
Reference< XController2 > xController( xModel2->createViewController( sViewName, Sequence< PropertyValue >(), rFrame ), UNO_SET_THROW );
- xController->attachModel( xModel );
- xModel->connectController( xController.get() );
- rFrame->setComponent( xController->getComponentWindow(), xController.get() );
- xController->attachFrame( rFrame );
- xModel->setCurrentController( xController.get() );
+ // introduce model/view/controller to each other
+ utl::ConnectFrameControllerModel(rFrame, xController, xModel);
bSuccess = true;
}
@@ -474,7 +472,7 @@ void SAL_CALL DBContentLoader::load(const Reference< XFrame > & rFrame, const OU
{
NamedDatabaseObject aSelection;
aSelection.Type = nInitialSelection;
- xDocView->select( makeAny( aSelection ) );
+ xDocView->select( Any( aSelection ) );
}
}