diff options
-rw-r--r-- | editeng/source/editeng/editdoc.cxx | 2 | ||||
-rw-r--r-- | filter/source/config/cache/filterfactory.cxx | 6 | ||||
-rw-r--r-- | fpicker/source/office/fileview.cxx | 5 | ||||
-rw-r--r-- | framework/source/services/desktop.cxx | 4 | ||||
-rw-r--r-- | framework/source/services/pathsettings.cxx | 5 |
5 files changed, 8 insertions, 14 deletions
diff --git a/editeng/source/editeng/editdoc.cxx b/editeng/source/editeng/editdoc.cxx index 9841d7854c32..7a5d70b34567 100644 --- a/editeng/source/editeng/editdoc.cxx +++ b/editeng/source/editeng/editdoc.cxx @@ -3009,7 +3009,7 @@ public: void CharAttribList::DeleteEmptyAttribs( SfxItemPool& rItemPool ) { std::for_each(aAttribs.begin(), aAttribs.end(), RemoveEmptyAttrItem(rItemPool)); - aAttribs.erase( std::remove_if(aAttribs.begin(), aAttribs.end(), [](const std::unique_ptr<EditCharAttrib>& aAttrib) { return aAttrib->IsEmpty(); } ), aAttribs.end() ); + std::erase_if(aAttribs, [](const std::unique_ptr<EditCharAttrib>& aAttrib) { return aAttrib->IsEmpty(); } ); bHasEmptyAttribs = false; } diff --git a/filter/source/config/cache/filterfactory.cxx b/filter/source/config/cache/filterfactory.cxx index 481dac67a7c3..1c6fadca6c86 100644 --- a/filter/source/config/cache/filterfactory.cxx +++ b/filter/source/config/cache/filterfactory.cxx @@ -443,13 +443,11 @@ std::vector<OUString> FilterFactory::impl_getSortedFilterListForModule(const OUS // remove all filters from this merged list, which does not fit the flag specification if (nIFlags != -1) { - auto pItToErase = ::std::remove_if(lMergedFilters.begin(), lMergedFilters.end(), stlcomp_removeIfMatchFlags(pCache, nIFlags, true)); - lMergedFilters.erase(pItToErase, lMergedFilters.end()); + std::erase_if(lMergedFilters, stlcomp_removeIfMatchFlags(pCache, nIFlags, true)); } if (nEFlags != -1) { - auto pItToErase = ::std::remove_if(lMergedFilters.begin(), lMergedFilters.end(), stlcomp_removeIfMatchFlags(pCache, nEFlags, false)); - lMergedFilters.erase(pItToErase, lMergedFilters.end()); + std::erase_if(lMergedFilters, stlcomp_removeIfMatchFlags(pCache, nEFlags, false)); } // sort the default filter to the front of this list diff --git a/fpicker/source/office/fileview.cxx b/fpicker/source/office/fileview.cxx index ebc3ee3b8b18..1fa1c4dafcd3 100644 --- a/fpicker/source/office/fileview.cxx +++ b/fpicker/source/office/fileview.cxx @@ -1304,7 +1304,7 @@ void SvtFileView_Impl::FilterFolderContent_Impl( std::u16string_view rFilter ) // do the filtering - maContent.erase(std::remove_if(maContent.begin(), maContent.end(), + std::erase_if(maContent, [&aFilters](const std::unique_ptr<SortingData_Impl>& rxContent) { if (rxContent->mbIsFolder) return false; @@ -1312,8 +1312,7 @@ void SvtFileView_Impl::FilterFolderContent_Impl( std::u16string_view rFilter ) // 91872 - 11.09.2001 - frank.schoenheit@sun.com OUString sCompareString = rxContent->GetFileName(); // filter works on file name, not on title! return std::none_of(aFilters.begin(), aFilters.end(), FilterMatch(sCompareString)); - }), - maContent.end()); + }); } IMPL_LINK_NOARG(SvtFileView_Impl, ChangedHdl, weld::TreeView&, void) diff --git a/framework/source/services/desktop.cxx b/framework/source/services/desktop.cxx index 35dfcd2e21eb..237d35afc6a5 100644 --- a/framework/source/services/desktop.cxx +++ b/framework/source/services/desktop.cxx @@ -443,9 +443,7 @@ void SAL_CALL Desktop::removeTerminateListener( const css::uno::Reference< css:: } else if (sImplementationName == "com.sun.star.comp.ComponentDLLListener") { - m_xComponentDllListeners.erase( - std::remove(m_xComponentDllListeners.begin(), m_xComponentDllListeners.end(), xListener), - m_xComponentDllListeners.end()); + std::erase(m_xComponentDllListeners, xListener); return; } } diff --git a/framework/source/services/pathsettings.cxx b/framework/source/services/pathsettings.cxx index 0a24b96adda7..36237e824edc 100644 --- a/framework/source/services/pathsettings.cxx +++ b/framework/source/services/pathsettings.cxx @@ -997,11 +997,10 @@ void PathSettings::impl_purgeKnownPaths(PathSettings::PathInfo& rPath, } // Erase items not in lList from the user path list. - rPath.lUserPaths.erase(std::remove_if(rPath.lUserPaths.begin(), rPath.lUserPaths.end(), + std::erase_if(rPath.lUserPaths, [&lList](const OUString& rItem) { return std::find(lList.begin(), lList.end(), rItem) == lList.end(); - }), - rPath.lUserPaths.end()); + }); // Erase items in the user path list from lList. for (auto const& userPath : rPath.lUserPaths) |