Fixed an issue where the text element containerStartDelay timer was sometimes not reset

This commit is contained in:
Leon Styhre 2024-12-21 13:15:11 +01:00
parent 8dcf9af6f3
commit 6a1d6e2844

View file

@ -174,6 +174,7 @@ void ScrollableContainer::update(int deltaTime)
// Don't scroll if the media viewer or screensaver is active or if text scrolling is disabled;
if (mWindow->isMediaViewerActive() || mWindow->isScreensaverActive() ||
!mWindow->getAllowTextScrolling()) {
mAutoScrollAccumulator = -mAutoScrollDelay;
if (mScrollPos != glm::vec2 {0.0f, 0.0f} && !mWindow->isLaunchScreenDisplayed())
resetComponent();
return;