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

Windows dialogs - Handle scenario when window is not visible yet. #1662

Merged
merged 2 commits into from
Jul 27, 2022

Conversation

leaanthony
Copy link
Member

@leaanthony leaanthony commented Jul 26, 2022

On Windows, if the window has not yet been activated, calls to dialog methods will crash due to some weirdness deep inside a windows syscall. This PR will use the desktop (nil HWND) if the window is not visible. Fixes #1660

@leaanthony leaanthony requested a review from stffabi July 26, 2022 22:33
@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Jul 27, 2022

Deploying with  Cloudflare Pages  Cloudflare Pages

Latest commit: 98bfaf6
Status: ✅  Deploy successful!
Preview URL: https://37f7a178.wails-website.pages.dev
Branch Preview URL: https://bugfix-windows-dialog-non-vi.wails-website.pages.dev

View logs

Copy link
Collaborator

@stffabi stffabi left a comment

Choose a reason for hiding this comment

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

LGTM 👍

@leaanthony leaanthony merged commit a229e04 into master Jul 27, 2022
@leaanthony leaanthony deleted the bugfix/windows-dialog-non-visible-window branch July 27, 2022 09:38
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.

[Windows] runtime.MessageDialog panics when called from "OnStartup" callback
2 participants