-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
darwin: add event ApplicationShouldHandleReopen #2991
Conversation
👷 Deploy request for dapper-pastelito-9b5e5b pending review.Visit the deploys page to approve it
|
Thanks for this! If you run |
@leaanthony Generated new ID list. It correct now? |
# Conflicts: # v3/pkg/events/events.go
- (BOOL)applicationShouldHandleReopen:(NSNotification *)notification | ||
hasVisibleWindows:(BOOL)flag { | ||
if( hasListeners(EventApplicationShouldHandleReopen) ) { | ||
processApplicationEvent(EventApplicationShouldHandleReopen, NULL); |
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.
Would it be useful to pass the flag with the event?
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.
Updated. The processApplicationEvent
now accept NSDirectory and will save to the ApplicationEventContext
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.
This is great. Thank you! 🙏
Description
This pull request add new Event ApplicationShouldHandleReopen to handle dock click in macOS.
This is useful to app which use close button to hide itself (Example in
examples/hide-window
).Type of change
How Has This Been Tested?
Tested in darwin in the example
Test Configuration
Checklist:
website/src/pages/changelog.mdx
with details of this PR