This is an automated email from the ASF dual-hosted git repository.

asf-gitbox-commits pushed a commit to branch compilers-101
in repository https://gitbox.apache.org/repos/asf/openoffice.git

commit 45f2c828d3da842715b7bea38980420842c0ea08
Author: Pedro F. Giffuni <[email protected]>
AuthorDate: Fri Nov 6 00:04:10 2026 -0500

    Boost modernization Phase 3 continued: boost::bind to C++14 lambdas (~15 
more files)
    
    - Replace boost::bind with C++14 lambdas in:
      - reportdesign/source/ui/inspection/GeometryHandler.cxx (appendListEntry 
x3, DefaultFunction::getName)
      - reportdesign/source/core/api/ReportDefinition.cxx (queryClosing, 
notifyStorageChange)
    - Remove #include <boost/bind.hpp> where no longer needed
---
 main/reportdesign/source/core/api/ReportDefinition.cxx     | 5 ++---
 main/reportdesign/source/ui/inspection/GeometryHandler.cxx | 9 ++++-----
 2 files changed, 6 insertions(+), 8 deletions(-)

diff --git a/main/reportdesign/source/core/api/ReportDefinition.cxx 
b/main/reportdesign/source/core/api/ReportDefinition.cxx
index 06f4d5f761..7f4aaec56f 100644
--- a/main/reportdesign/source/core/api/ReportDefinition.cxx
+++ b/main/reportdesign/source/core/api/ReportDefinition.cxx
@@ -119,7 +119,6 @@
 #include <vcl/virdev.hxx>
 #include <vos/mutex.hxx>
 
-#include <boost/bind.hpp>
 #include <boost/mem_fn.hpp>
 #include <boost/utility.hpp>
 #include <memory>
@@ -1264,7 +1263,7 @@ void SAL_CALL OReportDefinition::close( ::sal_Bool 
_bDeliverOwnership )
        lang::EventObject aEvt( static_cast< ::cppu::OWeakObject* >( this ) );
     aGuard.clear();
        m_pImpl->m_aCloseListener.forEach<util::XCloseListener>(
-               
::boost::bind(&util::XCloseListener::queryClosing,_1,boost::cref(aEvt),boost::cref(_bDeliverOwnership)));
+               [this, &aEvt, &_bDeliverOwnership](const auto& listener) { 
listener->queryClosing( aEvt, _bDeliverOwnership ); });
     aGuard.reset();
 
 
@@ -1674,7 +1673,7 @@ void SAL_CALL OReportDefinition::switchToStorage( const 
uno::Reference< embed::X
        // notify our container listeners
        OWeakObject *oWeakThis = static_cast<OWeakObject*>( this );
        
m_pImpl->m_aStorageChangeListeners.forEach<document::XStorageChangeListener>(
-                       
::boost::bind(&document::XStorageChangeListener::notifyStorageChange,_1,boost::cref(
 oWeakThis ),boost::cref(_xStorage)));
+                       [this, &oWeakThis, &_xStorage](const auto& listener) { 
listener->notifyStorageChange( oWeakThis, _xStorage ); });
 }
 // 
-----------------------------------------------------------------------------
 uno::Reference< embed::XStorage > SAL_CALL 
OReportDefinition::getDocumentStorage(  )
diff --git a/main/reportdesign/source/ui/inspection/GeometryHandler.cxx 
b/main/reportdesign/source/ui/inspection/GeometryHandler.cxx
index e61242d665..8c9ad885c7 100644
--- a/main/reportdesign/source/ui/inspection/GeometryHandler.cxx
+++ b/main/reportdesign/source/ui/inspection/GeometryHandler.cxx
@@ -75,7 +75,6 @@
 #include <connectivity/dbconversion.hxx>
 #include <connectivity/dbtools.hxx>
 
-#include <boost/bind.hpp>
 #include <tools/string.hxx>
 #include "metadata.hxx"
 #include <svl/itempool.hxx>
@@ -706,7 +705,7 @@ void GeometryHandler::implCreateListLikeControl(
     );
 
     out_Descriptor.Control = xListControl.get();
-    ::std::for_each( _aEntries.begin(), _aEntries.end(),::boost::bind( 
&inspection::XStringListControl::appendListEntry, xListControl,_1 ));
+    ::std::for_each( _aEntries.begin(), _aEntries.end(),[&](const auto& entry) 
{ xListControl->appendListEntry( entry ); } );
 }
 // 
-----------------------------------------------------------------------------
 
@@ -808,9 +807,9 @@ inspection::LineDescriptor SAL_CALL 
GeometryHandler::describePropertyLine(const
                 else
                 {
                     ::std::for_each( m_aFieldNames.getConstArray(), 
m_aFieldNames.getConstArray() + m_aFieldNames.getLength(),
-                        ::boost::bind( 
&inspection::XStringListControl::appendListEntry, xListControl, _1 ) );
+                        [&](const auto& entry) { 
xListControl->appendListEntry( entry ); } );
                     ::std::for_each( m_aParamNames.getConstArray(), 
m_aParamNames.getConstArray() + m_aParamNames.getLength(),
-                        ::boost::bind( 
&inspection::XStringListControl::appendListEntry, xListControl, _1 ) );
+                        [&](const auto& entry) { 
xListControl->appendListEntry( entry ); } );
                 }
             }
             break;
@@ -1647,7 +1646,7 @@ void GeometryHandler::checkPosAndSize(  const awt::Point& 
_aNewPos,
 void GeometryHandler::impl_fillFormulaList_nothrow(::std::vector< 
::rtl::OUString >& _out_rList) const
 {
     if ( m_nDataFieldType == FUNCTION )
-        
::std::transform(m_aDefaultFunctions.begin(),m_aDefaultFunctions.end(),::std::back_inserter(_out_rList),::boost::bind(
 &DefaultFunction::getName, _1 ));
+        
::std::transform(m_aDefaultFunctions.begin(),m_aDefaultFunctions.end(),::std::back_inserter(_out_rList),[](const
 auto& f) { return f.getName(); });
     else if ( m_nDataFieldType == USER_DEF_FUNCTION )
         
::std::transform(m_aFunctionNames.begin(),m_aFunctionNames.end(),::std::back_inserter(_out_rList),::std::select1st<TFunctions::value_type>());
 }

Reply via email to