mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 12:37:44 +00:00
AK+LibGUI: Pass predicate to *_matching() methods by const reference
This commit is contained in:
parent
6ed2ded77c
commit
a0a4d169f4
5 changed files with 12 additions and 12 deletions
|
@ -10,9 +10,9 @@
|
|||
|
||||
namespace GUI {
|
||||
|
||||
void ModelSelection::remove_all_matching(Function<bool(ModelIndex const&)> filter)
|
||||
void ModelSelection::remove_all_matching(Function<bool(ModelIndex const&)> const& filter)
|
||||
{
|
||||
if (m_indices.remove_all_matching([&](ModelIndex const& index) { return filter(index); }))
|
||||
if (m_indices.remove_all_matching(filter))
|
||||
notify_selection_changed();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue