summaryrefslogtreecommitdiff
path: root/fpicker
diff options
context:
space:
mode:
authorTino Rachui <tra@openoffice.org>2001-11-15 15:00:57 +0000
committerTino Rachui <tra@openoffice.org>2001-11-15 15:00:57 +0000
commite4ebdad8c48272b7ec7738a90d4edafe4cfea8bd (patch)
treeb4b87a20114eb366bfdf5a447405d956fc12397b /fpicker
parent245edd3fd0003dc66c77463c8c3004c1810bd783 (diff)
#94499#
Diffstat (limited to 'fpicker')
-rw-r--r--fpicker/source/win32/filepicker/asynceventnotifier.cxx54
1 files changed, 31 insertions, 23 deletions
diff --git a/fpicker/source/win32/filepicker/asynceventnotifier.cxx b/fpicker/source/win32/filepicker/asynceventnotifier.cxx
index 3f9ffb363d59..86a4a3d68ee7 100644
--- a/fpicker/source/win32/filepicker/asynceventnotifier.cxx
+++ b/fpicker/source/win32/filepicker/asynceventnotifier.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: asynceventnotifier.cxx,v $
*
- * $Revision: 1.1 $
+ * $Revision: 1.2 $
*
- * last change: $Author: tra $ $Date: 2001-11-15 15:51:26 $
+ * last change: $Author: tra $ $Date: 2001-11-15 16:00:57 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -147,34 +147,42 @@ void SAL_CALL CAsyncFilePickerEventNotifier::run( )
{
m_NotifyFilePickerEvent.wait( );
- while ( m_FilePickerEventList.size() > 0 )
+ if ( !m_rBroadcastHelper.bDisposed )
{
- ClearableMutexGuard aGuard( m_FilePickerEventListMutex );
+ ::osl::MutexGuard aGuard( m_rBroadcastHelper.rMutex );
- FilePickerEventRecord_t nextEventRecord = m_FilePickerEventList.front();
- m_FilePickerEventList.pop_front();
+ if ( !m_rBroadcastHelper.bDisposed )
+ {
+ while ( m_FilePickerEventList.size() > 0 )
+ {
+ ClearableMutexGuard aGuard( m_FilePickerEventListMutex );
- aGuard.clear();
+ FilePickerEventRecord_t nextEventRecord = m_FilePickerEventList.front();
+ m_FilePickerEventList.pop_front();
- ::cppu::OInterfaceContainerHelper* pICHelper =
- m_rBroadcastHelper.aLC.getContainer(getCppuType((Reference<XFilePickerListener>*)0) );
+ aGuard.clear();
- if ( pICHelper )
- {
- ::cppu::OInterfaceIteratorHelper iter( *pICHelper );
+ ::cppu::OInterfaceContainerHelper* pICHelper =
+ m_rBroadcastHelper.aLC.getContainer(getCppuType((Reference<XFilePickerListener>*)0) );
- while( iter.hasMoreElements() )
- {
- Reference< XFilePickerListener > xFPListener( iter.next( ), ::com::sun::star::uno::UNO_QUERY );
-
- try
- {
- if ( xFPListener.is() )
- (xFPListener.get()->*nextEventRecord.first)(nextEventRecord.second);
- }
- catch( RuntimeException& )
+ if ( pICHelper )
{
- OSL_ENSURE( sal_False, "RuntimeException during event dispatching" );
+ ::cppu::OInterfaceIteratorHelper iter( *pICHelper );
+
+ while( iter.hasMoreElements() )
+ {
+ Reference< XFilePickerListener > xFPListener( iter.next( ), ::com::sun::star::uno::UNO_QUERY );
+
+ try
+ {
+ if ( xFPListener.is() )
+ (xFPListener.get()->*nextEventRecord.first)(nextEventRecord.second);
+ }
+ catch( RuntimeException& )
+ {
+ OSL_ENSURE( sal_False, "RuntimeException during event dispatching" );
+ }
+ }
}
}
}