-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Mainmenu: Avoid the header being displayed behind the formspec #13924
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apparently the header was usually slightly behind the formspec on desktop as well, and this PR causes the header to move a few pixels when you open a dialog. I'll try to improve this. |
The header moves back and forth less again on desktop since my latest commit. But if the header usually ends up (slightly) behind the formspec even on desktop, maybe we should consider adjusting the original header placement code instead of just correcting its output. Anyway, the approach taken by this PR is probably fine as a simple fix for the Android issue. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works.
…est#13924) This change keeps the current header placement code, but adds additional code to make sure the header doesn't end up behind the formspec.
…est#13924) This change keeps the current header placement code, but adds additional code to make sure the header doesn't end up behind the formspec.
Currently, the mainmenu header image is usually displayed behind the mainmenu formspec on Android. This results in three problems:
This PR keeps the current header placement code, but adds additional code to make sure the header doesn't end up behind the formspec. I don't claim that it's beautiful now, but I think it's better than before.
Here's a before/after comparison on Android:
On desktop, it looks the same as before.
To do
This PR is a Ready for Review.
A future PR could move the mainmenu formspec down a bit, giving more space to the header.
How to test
Start Minetest on your Android device. Verify that the mainmenu header isn't displayed behind the mainmenu formspec.