From 7a1678065b533aad75d3687c6a59d35b30b9323c Mon Sep 17 00:00:00 2001 From: Ocke Janssen Date: Tue, 30 Oct 2001 10:03:59 +0000 Subject: #93950# remember if we are in drop --- connectivity/source/drivers/adabas/BViews.cxx | 9 +++++++-- connectivity/source/inc/adabas/BViews.hxx | 6 ++++-- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/connectivity/source/drivers/adabas/BViews.cxx b/connectivity/source/drivers/adabas/BViews.cxx index 798b90628b4b..6c7df1cbfb9f 100644 --- a/connectivity/source/drivers/adabas/BViews.cxx +++ b/connectivity/source/drivers/adabas/BViews.cxx @@ -2,9 +2,9 @@ * * $RCSfile: BViews.cxx,v $ * - * $Revision: 1.11 $ + * $Revision: 1.12 $ * - * last change: $Author: oj $ $Date: 2001-10-12 11:39:41 $ + * last change: $Author: oj $ $Date: 2001-10-30 11:03:21 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -194,6 +194,9 @@ void OViews::appendObject( const Reference< XPropertySet >& descriptor ) // XDrop void OViews::dropObject(sal_Int32 _nPos,const ::rtl::OUString _sElementName) { + if(m_bInDrop) + return; + ObjectIter aIter = m_aElements[_nPos]; if(!aIter->second.is()) // we want to drop a object which isn't loaded yet so we must load it @@ -228,7 +231,9 @@ void OViews::dropObject(sal_Int32 _nPos,const ::rtl::OUString _sElementName) // ----------------------------------------------------------------------------- void OViews::dropByNameImpl(const ::rtl::OUString& elementName) { + m_bInDrop = sal_True; OCollection_TYPE::dropByName(elementName); + m_bInDrop = sal_False; } // ----------------------------------------------------------------------------- void OViews::createView( const Reference< XPropertySet >& descriptor ) diff --git a/connectivity/source/inc/adabas/BViews.hxx b/connectivity/source/inc/adabas/BViews.hxx index f608c9ea0848..5eefce885973 100644 --- a/connectivity/source/inc/adabas/BViews.hxx +++ b/connectivity/source/inc/adabas/BViews.hxx @@ -2,9 +2,9 @@ * * $RCSfile: BViews.hxx,v $ * - * $Revision: 1.4 $ + * $Revision: 1.5 $ * - * last change: $Author: oj $ $Date: 2001-10-12 11:59:33 $ + * last change: $Author: oj $ $Date: 2001-10-30 11:03:59 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -74,6 +74,7 @@ namespace connectivity class OViews : public sdbcx::OCollection { ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XDatabaseMetaData > m_xMetaData; + sal_Bool m_bInDrop; // OCatalog* m_pParent; protected: virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XNamed > createObject(const ::rtl::OUString& _rName); @@ -88,6 +89,7 @@ namespace connectivity OViews(const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XDatabaseMetaData >& _rMetaData,::cppu::OWeakObject& _rParent, ::osl::Mutex& _rMutex, const TStringVector &_rVector) : sdbcx::OCollection(_rParent,sal_True,_rMutex,_rVector) ,m_xMetaData(_rMetaData) + ,m_bInDrop(sal_False) {} // only the name is identical to ::cppu::OComponentHelper -- cgit v1.2.3