Kaydet (Commit) 819fd244 authored tarafından Michael Stahl's avatar Michael Stahl

comphelper: replace boost::function with std::function

Change-Id: I042c97d8472c3afceffba36808687f382571e6c2
üst a713fb5e
...@@ -52,7 +52,7 @@ ScopeGuard::~ScopeGuard() ...@@ -52,7 +52,7 @@ ScopeGuard::~ScopeGuard()
void ScopeGuard::dismiss() void ScopeGuard::dismiss()
{ {
m_func.clear(); m_func = nullptr;
} }
FlagGuard::~FlagGuard() FlagGuard::~FlagGuard()
......
...@@ -21,7 +21,8 @@ ...@@ -21,7 +21,8 @@
#define INCLUDED_COMPHELPER_SCOPEGUARD_HXX #define INCLUDED_COMPHELPER_SCOPEGUARD_HXX
#include <comphelper/comphelperdllapi.h> #include <comphelper/comphelperdllapi.h>
#include <boost/function.hpp>
#include <functional>
namespace comphelper { namespace comphelper {
...@@ -53,7 +54,7 @@ private: ...@@ -53,7 +54,7 @@ private:
ScopeGuard(const ScopeGuard&) SAL_DELETED_FUNCTION; ScopeGuard(const ScopeGuard&) SAL_DELETED_FUNCTION;
ScopeGuard& operator=(const ScopeGuard&) SAL_DELETED_FUNCTION; ScopeGuard& operator=(const ScopeGuard&) SAL_DELETED_FUNCTION;
::boost::function0<void> m_func; // preferring portable syntax ::std::function<void ()> m_func;
exc_handling const m_excHandling; exc_handling const m_excHandling;
}; };
......
...@@ -25,22 +25,23 @@ ...@@ -25,22 +25,23 @@
#include <com/sun/star/lang/XServiceInfo.hpp> #include <com/sun/star/lang/XServiceInfo.hpp>
#include <uno/environment.h> #include <uno/environment.h>
#include <boost/noncopyable.hpp> #include <boost/noncopyable.hpp>
#include <boost/function.hpp>
#include <boost/preprocessor/cat.hpp> #include <boost/preprocessor/cat.hpp>
#include <boost/preprocessor/repetition.hpp> #include <boost/preprocessor/repetition.hpp>
#include <boost/preprocessor/seq/enum.hpp> #include <boost/preprocessor/seq/enum.hpp>
#include <functional>
namespace comphelper { namespace comphelper {
namespace service_decl { namespace service_decl {
class ServiceDecl; class ServiceDecl;
namespace detail { namespace detail {
typedef ::boost::function3< typedef ::std::function<
css::uno::Reference<css::uno::XInterface> /* return */, css::uno::Reference<css::uno::XInterface> /* return */
ServiceDecl const&, (ServiceDecl const&,
css::uno::Sequence<css::uno::Any> const&, css::uno::Sequence<css::uno::Any> const&,
css::uno::Reference<css::uno::XComponentContext> const&> CreateFuncF; css::uno::Reference<css::uno::XComponentContext> const&)> CreateFuncF;
} }
/** Class to declare a service implementation. There is no need to implement /** Class to declare a service implementation. There is no need to implement
......
...@@ -30,6 +30,7 @@ ...@@ -30,6 +30,7 @@
#include <vector> #include <vector>
#include <list> #include <list>
#include <limits> #include <limits>
#include <algorithm>
using ::com::sun::star::uno::Exception; using ::com::sun::star::uno::Exception;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment