[Libreoffice-commits] core.git: dbaccess/source
Lionel Elie Mamane
lionel at mamane.lu
Thu Jan 30 05:38:30 PST 2014
dbaccess/source/core/dataaccess/databasedocument.cxx | 27 ++++++++-----------
1 file changed, 12 insertions(+), 15 deletions(-)
New commits:
commit ce445c50d64062ea1476404a226c369aa96fd1fa
Author: Lionel Elie Mamane <lionel at mamane.lu>
Date: Thu Jan 30 14:36:17 2014 +0100
merge property map for import and export
why would they ever need to be different?
There was maybe/probably a bug lurking behind their being different.
Change-Id: I5db7f1596aec0d2a504ec7901c001054fd7fd121
diff --git a/dbaccess/source/core/dataaccess/databasedocument.cxx b/dbaccess/source/core/dataaccess/databasedocument.cxx
index 37e4688..7cf642b 100644
--- a/dbaccess/source/core/dataaccess/databasedocument.cxx
+++ b/dbaccess/source/core/dataaccess/databasedocument.cxx
@@ -481,20 +481,25 @@ void ODatabaseDocument::impl_reset_nothrow()
m_pImpl->m_bDocumentReadOnly = sal_False;
}
-void ODatabaseDocument::impl_import_nolck_throw( const Reference< XComponentContext >& _rContext, const Reference< XInterface >& _rxTargetComponent,
- const ::comphelper::NamedValueCollection& _rResource )
+namespace
{
- Sequence< Any > aFilterCreationArgs;
- Reference< XStatusIndicator > xStatusIndicator;
- lcl_extractAndStartStatusIndicator( _rResource, xStatusIndicator, aFilterCreationArgs );
-
- /** property map for import info set */
+ /** property map for import/exmport info set */
comphelper::PropertyMapEntry const aExportInfoMap[] =
{
{ OUString("BaseURI"), 0, ::getCppuType( (OUString *)0 ),beans::PropertyAttribute::MAYBEVOID, 0 },
{ OUString("StreamName"), 0, ::getCppuType( (OUString *)0 ),beans::PropertyAttribute::MAYBEVOID, 0 },
+ { OUString("UsePrettyPrinting"), 0, ::getCppuType((sal_Bool*)0), beans::PropertyAttribute::MAYBEVOID, 0},
{ OUString(), 0, css::uno::Type(), 0, 0 }
};
+}
+
+void ODatabaseDocument::impl_import_nolck_throw( const Reference< XComponentContext >& _rContext, const Reference< XInterface >& _rxTargetComponent,
+ const ::comphelper::NamedValueCollection& _rResource )
+{
+ Sequence< Any > aFilterCreationArgs;
+ Reference< XStatusIndicator > xStatusIndicator;
+ lcl_extractAndStartStatusIndicator( _rResource, xStatusIndicator, aFilterCreationArgs );
+
uno::Reference< beans::XPropertySet > xInfoSet( comphelper::GenericPropertySet_CreateInstance( new comphelper::PropertySetInfo( aExportInfoMap ) ) );
xInfoSet->setPropertyValue("BaseURI", uno::makeAny(_rResource.getOrDefault("URL",OUString())));
xInfoSet->setPropertyValue("StreamName", uno::makeAny(OUString("content.xml")));
@@ -1606,14 +1611,6 @@ void ODatabaseDocument::impl_writeStorage_throw( const Reference< XStorage >& _r
Sequence< Any > aDelegatorArguments;
lcl_extractStatusIndicator( _rMediaDescriptor, aDelegatorArguments );
- /** property map for export info set */
- comphelper::PropertyMapEntry aExportInfoMap[] =
- {
- { OUString("BaseURI"), 0, ::getCppuType( (OUString *)0 ),beans::PropertyAttribute::MAYBEVOID, 0 },
- { OUString("StreamName"), 0, ::getCppuType( (OUString *)0 ),beans::PropertyAttribute::MAYBEVOID, 0 },
- { OUString("UsePrettyPrinting"), 0, ::getCppuType((sal_Bool*)0), beans::PropertyAttribute::MAYBEVOID, 0},
- { OUString(), 0, css::uno::Type(), 0, 0 }
- };
uno::Reference< beans::XPropertySet > xInfoSet( comphelper::GenericPropertySet_CreateInstance( new comphelper::PropertySetInfo( aExportInfoMap ) ) );
SvtSaveOptions aSaveOpt;
More information about the Libreoffice-commits
mailing list