1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00

Projucer: Fixed a bug when highlighting the global JUCE path property component bounds

This commit is contained in:
ed 2021-05-26 14:48:05 +01:00
parent 083a5af323
commit 6b29a6d8ff

View file

@ -125,15 +125,18 @@ public:
if (isTimerRunning() || ! isSelectedOSThisOS())
return;
PropertyComponent* jucePathPropertyComponent = nullptr;
for (const auto& prop : propertyGroup.getProperties())
if (prop->getName() == "Path to JUCE")
jucePathPropertyComponent = prop.get();
if (jucePathPropertyComponent != nullptr)
const auto findJucePathPropertyComponent = [this]() -> PropertyComponent*
{
boundsToHighlight = getLocalArea (&propertyGroup, jucePathPropertyComponent->getBounds());
for (const auto& prop : propertyGroup.getProperties())
if (prop->getName() == "Path to JUCE")
return prop.get();
return nullptr;
};
if (auto* propComponent = findJucePathPropertyComponent())
{
boundsToHighlight = getLocalArea (nullptr, propComponent->getScreenBounds());
flashAlpha = 0.0f;
hasFlashed = false;