diff options
author | Takeshi Abe <tabe@fixedpoint.jp> | 2015-05-08 17:29:01 +0900 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2015-05-08 15:54:12 +0000 |
commit | 99e60d8d62b69d8b0b22d54e3f55c5151e7a2c2f (patch) | |
tree | 6385680c4ad53010b37982946d19643d7a35ae9a | |
parent | 12bb6a054d697efddee76269605ed2450a2fae9c (diff) |
std::ptr_fun became deprecated since C++11
Change-Id: If93609d032c9864e0251230bf9ed76e6b6741a62
Reviewed-on: https://gerrit.libreoffice.org/15672
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r-- | canvas/source/directx/dx_spritecanvashelper.cxx | 8 | ||||
-rw-r--r-- | forms/source/xforms/binding.cxx | 6 | ||||
-rw-r--r-- | jvmfwk/source/framework.cxx | 4 | ||||
-rw-r--r-- | xmloff/source/forms/layerimport.cxx | 10 |
4 files changed, 13 insertions, 15 deletions
diff --git a/canvas/source/directx/dx_spritecanvashelper.cxx b/canvas/source/directx/dx_spritecanvashelper.cxx index db7f9352f2df..67f0d8184114 100644 --- a/canvas/source/directx/dx_spritecanvashelper.cxx +++ b/canvas/source/directx/dx_spritecanvashelper.cxx @@ -235,7 +235,7 @@ namespace dxcanvas mpBackBuffer->draw(aUpdateArea); // redraw sprites - mpRedrawManager->forEachSprite(::std::ptr_fun( &spriteRedraw ) ); + mpRedrawManager->forEachSprite( &spriteRedraw ); // flip primary surface to screen // ============================== @@ -290,7 +290,7 @@ namespace dxcanvas // are avoided. ::std::for_each( rUpdateArea.maComponentList.begin(), rUpdateArea.maComponentList.end(), - ::std::ptr_fun( &spriteRedrawStub2 ) ); + &spriteRedrawStub2 ); // repaint uncovered areas from backbuffer - take the // _rounded_ rectangles from above, to have the update @@ -328,7 +328,7 @@ namespace dxcanvas // buffer. ::std::for_each( rSortedUpdateSprites.begin(), rSortedUpdateSprites.end(), - ::std::ptr_fun( &spriteRedrawStub ) ); + &spriteRedrawStub ); // TODO(E1): Use numeric_cast to catch overflow here ::basegfx::B2IRange aActualArea( 0, 0, @@ -364,7 +364,7 @@ namespace dxcanvas ::std::for_each( rSortedUpdateSprites.begin(), rSortedUpdateSprites.end(), - ::std::ptr_fun( &spriteRedrawStub ) ); + &spriteRedrawStub ); // add given update area to the 'blit to foreground' rect maUpdateRect.expand( aActualArea ); diff --git a/forms/source/xforms/binding.cxx b/forms/source/xforms/binding.cxx index b7312cbd44e1..96487e3d030e 100644 --- a/forms/source/xforms/binding.cxx +++ b/forms/source/xforms/binding.cxx @@ -712,13 +712,13 @@ void Binding::valueModified() Reference<XInterface> xSource = static_cast<XPropertySet*>( this ); ::std::for_each( maModifyListeners.begin(), maModifyListeners.end(), - ::std::bind2nd( ::std::ptr_fun( lcl_modified ), xSource ) ); + ::std::bind( lcl_modified, std::placeholders::_1, xSource ) ); ::std::for_each( maListEntryListeners.begin(), maListEntryListeners.end(), - ::std::bind2nd( ::std::ptr_fun( lcl_listentry ), xSource ) ); + ::std::bind( lcl_listentry, std::placeholders::_1, xSource ) ); ::std::for_each( maValidityListeners.begin(), maValidityListeners.end(), - ::std::bind2nd( ::std::ptr_fun( lcl_validate ), xSource ) ); + ::std::bind( lcl_validate, std::placeholders::_1, xSource ) ); // now distribute MIPs to children if( xNode.is() ) diff --git a/jvmfwk/source/framework.cxx b/jvmfwk/source/framework.cxx index ddfc4bfbea55..7035bba85dc1 100644 --- a/jvmfwk/source/framework.cxx +++ b/jvmfwk/source/framework.cxx @@ -136,7 +136,7 @@ javaFrameworkError SAL_CALL jfw_findAllJREs(JavaInfo ***pparInfo, sal_Int32 *pSi //the same JRE it_info it_duplicate = std::find_if(vecInfoManual.begin(), vecInfoManual.end(), - std::bind2nd(std::ptr_fun(areEqualJavaInfo), aInfo)); + std::bind(areEqualJavaInfo, std::placeholders::_1, aInfo)); if (it_duplicate == vecInfoManual.end()) vecInfoManual.push_back(aInfo); } @@ -165,7 +165,7 @@ javaFrameworkError SAL_CALL jfw_findAllJREs(JavaInfo ***pparInfo, sal_Int32 *pSi { it_info it_duplicate = std::find_if(vecInfoManual2.begin(), vecInfoManual2.end(), - std::bind2nd(std::ptr_fun(areEqualJavaInfo), *j)); + std::bind(areEqualJavaInfo, std::placeholders::_1, *j)); if (it_duplicate != vecInfoManual2.end()) vecInfoManual2.erase(it_duplicate); } diff --git a/xmloff/source/forms/layerimport.cxx b/xmloff/source/forms/layerimport.cxx index 33459eb45ed1..453c49009842 100644 --- a/xmloff/source/forms/layerimport.cxx +++ b/xmloff/source/forms/layerimport.cxx @@ -52,6 +52,7 @@ #include <xmloff/xmlnmspe.hxx> #include <rtl/strbuf.hxx> #include <algorithm> +#include <functional> namespace xmloff { @@ -581,18 +582,15 @@ void OFormLayerXMLImport_Impl::documentDone( ) // process XForms-bindings; call registerXFormsValueBinding for each std::for_each( m_aXFormsValueBindings.begin(), m_aXFormsValueBindings.end(), - bind1st( ptr_fun( bindXFormsValueBinding ), - rImport.GetModel() ) ); + std::bind( bindXFormsValueBinding, rImport.GetModel(), std::placeholders::_1 ) ); // same for list bindings std::for_each( m_aXFormsListBindings.begin(), m_aXFormsListBindings.end(), - bind1st( ptr_fun( bindXFormsListBinding ), - rImport.GetModel() ) ); + std::bind( bindXFormsListBinding, rImport.GetModel(), std::placeholders::_1 ) ); // same for submissions std::for_each( m_aXFormsSubmissions.begin(), m_aXFormsSubmissions.end(), - bind1st( ptr_fun( bindXFormsSubmission ), - rImport.GetModel() ) ); + std::bind( bindXFormsSubmission, rImport.GetModel(), std::placeholders::_1 ) ); } } // namespace xmloff |