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

Fix the menu position on macOS when using Qt 6.5 #4595

Merged
merged 2 commits into from
May 2, 2023

Conversation

pajlada
Copy link
Member

@pajlada pajlada commented May 2, 2023

Description

Reported in Discord by Trummler - see video: https://cdn.discordapp.com/attachments/459650160658481152/1103008038576721921/Bildschirmaufnahme_2023-05-02_um_19.19.36.mov

This happened because we called popup then move on the menu, and the position was only correct when the move call was called because the size had not yet been evaluated in the menu.
Instead, when figuring out the position, we now use the menu's sizehint which should be correct even before the menu is ever shown.

@pajlada
Copy link
Member Author

pajlada commented May 2, 2023

Confirmed working as expected on macOS Qt 6.5, macOS Qt 5.15, Arch Linux Qt 6.2.4, Arch Linux Qt 5.15

@pajlada pajlada marked this pull request as ready for review May 2, 2023 18:31
Copy link
Collaborator

@Felanbird Felanbird left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems fine on 🅱️ indows, which the original issue did not effect - tested both 6.5 and 5.15

@pajlada pajlada merged commit 6672adf into master May 2, 2023
@pajlada pajlada deleted the fix/menu-position-fix branch May 2, 2023 18:50
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.

None yet

2 participants