diff --git a/modules/juce_gui_basics/misc/juce_JUCESplashScreen.cpp b/modules/juce_gui_basics/misc/juce_JUCESplashScreen.cpp index 1e6e1cd2a0..3c0b527ade 100644 --- a/modules/juce_gui_basics/misc/juce_JUCESplashScreen.cpp +++ b/modules/juce_gui_basics/misc/juce_JUCESplashScreen.cpp @@ -57,7 +57,7 @@ namespace juce static const int millisecondsToDisplaySplash = 2000, splashScreenFadeOutTime = 2000; static const int splashScreenLogoWidth = 123, splashScreenLogoHeight = 63; static uint32 splashDisplayTime = 0; -static bool appUsageReported = false; +static bool splashHasStartedFading = false, appUsageReported = false; static Rectangle getLogoArea (Rectangle parentRect) @@ -150,7 +150,6 @@ void ReportingThreadContainer::changeListenerCallback (ChangeBroadcaster*) //============================================================================== JUCESplashScreen::JUCESplashScreen (Component& parent) { - ignoreUnused (hasStartedFading); ignoreUnused (parent); #if JUCE_REPORT_APP_USAGE @@ -326,13 +325,13 @@ void JUCESplashScreen::paint (Graphics& g) void JUCESplashScreen::timerCallback() { #if JUCE_DISPLAY_SPLASH_SCREEN - if (isVisible() && ! hasStartedFading) + if (isVisible() && ! splashHasStartedFading) { - hasStartedFading = true; + splashHasStartedFading = true; fader.animateComponent (this, getBounds(), 0.0f, splashScreenFadeOutTime, false, 0, 0); } - if (hasStartedFading && ! fader.isAnimating()) + if (splashHasStartedFading && ! fader.isAnimating()) #endif delete this; } @@ -351,7 +350,7 @@ void JUCESplashScreen::parentHierarchyChanged() bool JUCESplashScreen::hitTest (int x, int y) { - if (! hasStartedFading) + if (! splashHasStartedFading) return getLogoArea (getLocalBounds().toFloat()).contains ((float) x, (float) y); return false; diff --git a/modules/juce_gui_basics/misc/juce_JUCESplashScreen.h b/modules/juce_gui_basics/misc/juce_JUCESplashScreen.h index b8b2209778..3f84aa9839 100644 --- a/modules/juce_gui_basics/misc/juce_JUCESplashScreen.h +++ b/modules/juce_gui_basics/misc/juce_JUCESplashScreen.h @@ -68,7 +68,6 @@ private: std::unique_ptr content; CriticalSection appUsageReporting; ComponentAnimator fader; - bool hasStartedFading = false; JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (JUCESplashScreen) };