1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-25 02:04:23 +00:00

Projucer: Improved file filter method

This commit is contained in:
ed 2017-06-21 17:03:01 +01:00
parent a1b55a4025
commit 238bca7420

View file

@ -82,19 +82,16 @@ public:
bool isGroupEmpty (const Project::Item& group) // recursive
{
bool isEmpty = true;
for (auto i = 0; i < group.getNumChildren(); ++i)
{
auto child = group.getChild (i);
if (child.isGroup())
isEmpty = isGroupEmpty (child);
else if (child.isFile() && child.getName().containsIgnoreCase (searchFilter))
isEmpty = false;
if ((child.isGroup() && ! isGroupEmpty (child))
|| (child.isFile() && child.getName().containsIgnoreCase (searchFilter)))
return false;
}
return isEmpty;
return true;
}
ProjectTreeItemBase* createSubItem (const Project::Item& child) override