summaryrefslogtreecommitdiffstats
path: root/fpicker/source/office/contentenumeration.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'fpicker/source/office/contentenumeration.cxx')
-rw-r--r--fpicker/source/office/contentenumeration.cxx26
1 files changed, 11 insertions, 15 deletions
diff --git a/fpicker/source/office/contentenumeration.cxx b/fpicker/source/office/contentenumeration.cxx
index 737808e10b62..2a5b0156480a 100644
--- a/fpicker/source/office/contentenumeration.cxx
+++ b/fpicker/source/office/contentenumeration.cxx
@@ -32,7 +32,7 @@
#include <vcl/svapp.hxx>
#include <osl/mutex.hxx>
#include <osl/diagnose.h>
-#include <tools/diagnose_ex.h>
+#include <comphelper/diagnose_ex.hxx>
#include <tools/urlobj.hxx>
namespace svt
@@ -63,9 +63,6 @@ namespace svt
using ::com::sun::star::ucb::CommandAbortedException;
using ::com::sun::star::ucb::XContentAccess;
using ::com::sun::star::ucb::XCommandEnvironment;
- using ::com::sun::star::beans::PropertyValue;
- using ::com::sun::star::document::DocumentProperties;
- using ::ucbhelper::ResultSetInclude;
using ::ucbhelper::INCLUDE_FOLDERS_AND_DOCUMENTS;
@@ -92,7 +89,7 @@ namespace svt
void FileViewContentEnumerator::cancel()
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
m_bCancelled = true;
m_pResultHandler = nullptr;
m_aFolder.aContent = ::ucbhelper::Content();
@@ -105,7 +102,7 @@ namespace svt
const css::uno::Sequence< OUString >& rDenyList )
{
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
m_aFolder = _rFolder;
m_pResultHandler = nullptr;
m_rDenyList = rDenyList;
@@ -117,7 +114,7 @@ namespace svt
void FileViewContentEnumerator::enumerateFolderContent(
const FolderDescriptor& _rFolder, IEnumerationResultHandler* _pResultHandler )
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
m_aFolder = _rFolder;
m_pResultHandler = _pResultHandler;
@@ -157,7 +154,7 @@ namespace svt
{
FolderDescriptor aFolder;
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
aFolder = m_aFolder;
xEnvironment = m_xCommandEnv;
}
@@ -165,7 +162,7 @@ namespace svt
{
aFolder.aContent = ::ucbhelper::Content( aFolder.sURL, xEnvironment, comphelper::getProcessComponentContext() );
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
m_aFolder.aContent = aFolder.aContent;
}
}
@@ -215,7 +212,7 @@ namespace svt
// check for restrictions
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
if ( /* m_rDenyList.hasElements() && */ URLOnDenyList ( sRealURL ) )
continue;
}
@@ -251,7 +248,6 @@ namespace svt
if ( pData->mbIsFolder )
{
- SolarMutexGuard aGuard;
::svtools::VolumeInfo aVolInfo( pData->mbIsVolume, pData->mbIsRemote,
pData->mbIsRemoveable, pData->mbIsFloppy,
pData->mbIsCompactDisc );
@@ -268,7 +264,7 @@ namespace svt
}
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
bCancelled = m_bCancelled;
}
}
@@ -287,7 +283,7 @@ namespace svt
IEnumerationResultHandler* pHandler = nullptr;
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
pHandler = m_pResultHandler;
if ( m_bCancelled )
return EnumerationResult::ERROR;
@@ -306,9 +302,9 @@ namespace svt
}
- bool FileViewContentEnumerator::URLOnDenyList ( const OUString& sRealURL )
+ bool FileViewContentEnumerator::URLOnDenyList ( std::u16string_view sRealURL )
{
- OUString entryName = sRealURL.copy( sRealURL.lastIndexOf( '/' ) + 1 );
+ std::u16string_view entryName = sRealURL.substr( sRealURL.rfind( '/' ) + 1 );
return comphelper::findValue(m_rDenyList, entryName) != -1;
}