dbaccess: replace boost::bind with C++11 lambdas
Change-Id: I468f9c7af9c8c8189c51790e0301dd8c60a9f83c
This commit is contained in:
parent
28159e91ba
commit
c567c0cf44
@ -49,7 +49,6 @@
|
|||||||
#include <type_traits>
|
#include <type_traits>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
#include <boost/bind.hpp>
|
|
||||||
#include <boost/intrusive_ptr.hpp>
|
#include <boost/intrusive_ptr.hpp>
|
||||||
#include <boost/optional.hpp>
|
#include <boost/optional.hpp>
|
||||||
#include <boost/optional/optional.hpp>
|
#include <boost/optional/optional.hpp>
|
||||||
|
@ -31,7 +31,6 @@
|
|||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
#include <boost/bind.hpp>
|
|
||||||
#include <boost/intrusive_ptr.hpp>
|
#include <boost/intrusive_ptr.hpp>
|
||||||
#include <boost/optional.hpp>
|
#include <boost/optional.hpp>
|
||||||
#include <osl/diagnose.h>
|
#include <osl/diagnose.h>
|
||||||
|
@ -81,8 +81,6 @@
|
|||||||
#include <osl/diagnose.h>
|
#include <osl/diagnose.h>
|
||||||
#include <tools/errcode.hxx>
|
#include <tools/errcode.hxx>
|
||||||
|
|
||||||
#include <boost/bind.hpp>
|
|
||||||
|
|
||||||
#include <functional>
|
#include <functional>
|
||||||
#include <list>
|
#include <list>
|
||||||
|
|
||||||
@ -1500,7 +1498,8 @@ void ODatabaseDocument::impl_disposeControllerFrames_nothrow()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void SAL_CALL ODatabaseDocument::close( sal_Bool _bDeliverOwnership ) throw (CloseVetoException, RuntimeException, std::exception)
|
void SAL_CALL ODatabaseDocument::close(sal_Bool bDeliverOwnership)
|
||||||
|
throw (CloseVetoException, RuntimeException, std::exception)
|
||||||
{
|
{
|
||||||
// nearly everything below can/must be done without our mutex locked, the below is just for
|
// nearly everything below can/must be done without our mutex locked, the below is just for
|
||||||
// the checks for being disposed and the like
|
// the checks for being disposed and the like
|
||||||
@ -1517,12 +1516,14 @@ void SAL_CALL ODatabaseDocument::close( sal_Bool _bDeliverOwnership ) throw (Clo
|
|||||||
// allow listeners to veto
|
// allow listeners to veto
|
||||||
lang::EventObject aEvent( *this );
|
lang::EventObject aEvent( *this );
|
||||||
m_aCloseListener.forEach< XCloseListener >(
|
m_aCloseListener.forEach< XCloseListener >(
|
||||||
boost::bind( &XCloseListener::queryClosing, _1, boost::cref( aEvent ), boost::cref( _bDeliverOwnership ) ) );
|
[&aEvent, &bDeliverOwnership] (uno::Reference<XCloseListener> const& xListener) {
|
||||||
|
return xListener->queryClosing(aEvent, bDeliverOwnership);
|
||||||
|
});
|
||||||
|
|
||||||
// notify that we're going to unload
|
// notify that we're going to unload
|
||||||
m_aEventNotifier.notifyDocumentEvent( "OnPrepareUnload" );
|
m_aEventNotifier.notifyDocumentEvent( "OnPrepareUnload" );
|
||||||
|
|
||||||
impl_closeControllerFrames_nolck_throw( _bDeliverOwnership );
|
impl_closeControllerFrames_nolck_throw( bDeliverOwnership );
|
||||||
|
|
||||||
m_aCloseListener.notifyEach( &XCloseListener::notifyClosing, (const lang::EventObject&)aEvent );
|
m_aCloseListener.notifyEach( &XCloseListener::notifyClosing, (const lang::EventObject&)aEvent );
|
||||||
|
|
||||||
@ -1777,12 +1778,14 @@ Sequence< OUString > SAL_CALL ODatabaseDocument::getDocumentSubStoragesNames( )
|
|||||||
return xStorageAccess->getDocumentSubStoragesNames();
|
return xStorageAccess->getDocumentSubStoragesNames();
|
||||||
}
|
}
|
||||||
|
|
||||||
void ODatabaseDocument::impl_notifyStorageChange_nolck_nothrow( const Reference< XStorage >& _rxNewRootStorage )
|
void ODatabaseDocument::impl_notifyStorageChange_nolck_nothrow( const Reference< XStorage >& xNewRootStorage )
|
||||||
{
|
{
|
||||||
Reference< XInterface > xMe( *this );
|
Reference< XInterface > xMe( *this );
|
||||||
|
|
||||||
m_aStorageListeners.forEach< XStorageChangeListener >(
|
m_aStorageListeners.forEach< XStorageChangeListener >(
|
||||||
boost::bind( &XStorageChangeListener::notifyStorageChange, _1, boost::cref( xMe ), boost::cref( _rxNewRootStorage ) ) );
|
[&xMe, &xNewRootStorage] (uno::Reference<XStorageChangeListener> const& xListener) {
|
||||||
|
return xListener->notifyStorageChange(xMe, xNewRootStorage);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
void ODatabaseDocument::disposing()
|
void ODatabaseDocument::disposing()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user