Lambda captures clean up, plus other minor clean ups.

This commit is contained in:
Martín Lucas Golini
2024-02-17 18:19:55 -03:00
parent b2a5b37802
commit 36c91989d3
41 changed files with 180 additions and 169 deletions

View File

@@ -38,7 +38,7 @@ void ProjectDirectoryTree::scan( const ProjectDirectoryTree::ScanCompleteEvent&
const bool& ignoreHidden ) {
#if EE_PLATFORM != EE_PLATFORM_EMSCRIPTEN || defined( __EMSCRIPTEN_PTHREADS__ )
mPool->run(
[&, acceptedPatterns, ignoreHidden] {
[this, acceptedPatterns, ignoreHidden] {
#endif
Lock l( mFilesMutex );
mRunning = true;
@@ -161,12 +161,12 @@ std::shared_ptr<FileListModel> ProjectDirectoryTree::matchTree( const std::strin
void ProjectDirectoryTree::asyncFuzzyMatchTree( const std::string& match, const size_t& max,
ProjectDirectoryTree::MatchResultCb res ) const {
mPool->run( [&, match, max, res]() { res( fuzzyMatchTree( match, max ) ); } );
mPool->run( [this, match, max, res]() { res( fuzzyMatchTree( match, max ) ); } );
}
void ProjectDirectoryTree::asyncMatchTree( const std::string& match, const size_t& max,
ProjectDirectoryTree::MatchResultCb res ) const {
mPool->run( [&, match, max, res]() { res( matchTree( match, max ) ); } );
mPool->run( [this, match, max, res]() { res( matchTree( match, max ) ); } );
}
std::shared_ptr<FileListModel>