Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent immediate window restore from minimize in core_window_flags #4863

Merged
merged 1 commit into from
Mar 28, 2025

Conversation

marler8997
Copy link
Contributor

The core_window_flags example automatically restores the window from being minimized after 3 seconds. However, it only resets the frameCounter if the window is minimized through the app from inputting KEY_N. This means if you miminize the window by other means (like pressing the minimize button) then the example will immediately restore the window because the frame counter wasn't reset. I've fixed this by setting the frameCounter back to 0 once it's expired. I also added a note in the UI that the example automatically restores the window so it's not a surprise.

The core_window_flags example automatically restores the window from
being minimized after 3 seconds. However, it only resets the frameCounter
if the window is minimized through the app from inputting KEY_N.  This
means if you miminize the window by other means (like pressing the minimize
button) then the example will immediately restore the window because the
frame counter wasn't reset. I've fixed this by setting the frameCounter
back to 0 once it's expired. I also added a note in the UI that the example
automatically restores the window so it's not a surprise.
@raysan5 raysan5 merged commit 61aea24 into raysan5:master Mar 28, 2025
15 checks passed
@raysan5
Copy link
Owner

raysan5 commented Mar 28, 2025

@marler8997 thanks for the review

@marler8997 marler8997 deleted the fixImmediateRestore branch March 28, 2025 22:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants