From 5837402fb1daa437d9a1a37edc9ede57319944f1 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Fri, 2 Nov 2012 17:46:30 +0200 Subject: fdo#46808, use service constructor for ucb::SimpleFileAccess I upgraded the service to return XSimpleFileAccess3, since it already implemented that interface, and it's backwards compatible. Change-Id: I40001a46048bd21a23b6a2f58a95376f06fc634b --- sd/source/filter/html/htmlex.cxx | 4 ++-- sd/source/filter/html/htmlex.hxx | 4 ++-- sd/source/ui/dlg/dlgass.cxx | 3 +-- 3 files changed, 5 insertions(+), 6 deletions(-) (limited to 'sd') diff --git a/sd/source/filter/html/htmlex.cxx b/sd/source/filter/html/htmlex.cxx index f63fb5e9d89f..3c690634b7fb 100644 --- a/sd/source/filter/html/htmlex.cxx +++ b/sd/source/filter/html/htmlex.cxx @@ -3099,7 +3099,7 @@ bool HtmlExport::CopyFile( const String& rSourceFile, const String& rDestPath ) // ===================================================================== -bool HtmlExport::checkFileExists( Reference< ::com::sun::star::ucb::XSimpleFileAccess2 >& xFileAccess, String const & aFileName ) +bool HtmlExport::checkFileExists( Reference< ::com::sun::star::ucb::XSimpleFileAccess3 >& xFileAccess, String const & aFileName ) { try { @@ -3125,7 +3125,7 @@ bool HtmlExport::checkForExistingFiles() try { Reference< XComponentContext > xContext( ::comphelper::getProcessComponentContext() ); - uno::Reference xFA(ucb::SimpleFileAccess::create(xContext)); + uno::Reference xFA(ucb::SimpleFileAccess::create(xContext)); sal_uInt16 nSdPage; for( nSdPage = 0; !bFound && (nSdPage < mnSdPageCount); nSdPage++) diff --git a/sd/source/filter/html/htmlex.hxx b/sd/source/filter/html/htmlex.hxx index 7a4ac0061c78..38e22bc230f5 100644 --- a/sd/source/filter/html/htmlex.hxx +++ b/sd/source/filter/html/htmlex.hxx @@ -30,7 +30,7 @@ #define _SD_HTMLEX_HXX #include -#include +#include #include #include #include "resltn.hxx" // enum PublishingResolution @@ -177,7 +177,7 @@ class HtmlExport bool CreateImageNumberFile(); bool checkForExistingFiles(); - bool checkFileExists( ::com::sun::star::uno::Reference< ::com::sun::star::ucb::XSimpleFileAccess2 >& xFileAccess, String const & aFileName ); + bool checkFileExists( ::com::sun::star::uno::Reference< ::com::sun::star::ucb::XSimpleFileAccess3 >& xFileAccess, String const & aFileName ); String getDocumentTitle(); bool SavePresentation(); diff --git a/sd/source/ui/dlg/dlgass.cxx b/sd/source/ui/dlg/dlgass.cxx index c34bb2ed116a..2dd1cc63d7a3 100644 --- a/sd/source/ui/dlg/dlgass.cxx +++ b/sd/source/ui/dlg/dlgass.cxx @@ -60,7 +60,6 @@ #include #include #include -#include #include #include #include @@ -792,7 +791,7 @@ void AssistentDlgImpl::ScanDocmenu (void) uno::Reference< lang::XMultiServiceFactory > xFactory( ::comphelper::getProcessServiceFactory() ); uno::Reference< container::XNameAccess > xFilterFactory( xFactory->createInstance( "com.sun.star.document.FilterFactory" ), uno::UNO_QUERY ); - uno::Reference xFileAccess(ucb::SimpleFileAccess::create(::comphelper::getProcessComponentContext())); + uno::Reference xFileAccess(ucb::SimpleFileAccess::create(::comphelper::getProcessComponentContext())); sal_uInt32 nCount = aHistory.getLength(); for (sal_uInt32 nItem=0; nItem