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

Implement more input callbacks #31

Merged
merged 5 commits into from
Dec 21, 2024
Merged

Implement more input callbacks #31

merged 5 commits into from
Dec 21, 2024

Conversation

foxnne
Copy link
Contributor

@foxnne foxnne commented Dec 12, 2024

This contains all necessary new input related callbacks/functions to get pixi back working on macos with scrolling, mouse movement, buttons, etc.

  • By selecting this checkbox, I agree to license my contributions to this project under the license(s) described in the LICENSE file, and I have the right to do so or have received permission to do so by an employer or client I am producing work for whom has this right.

@@ -39,4 +39,8 @@ - (NSApplicationTerminateReply)applicationShouldTerminate:(NSApplication *)sende
return NSTerminateCancel;
}

- (BOOL)applicationShouldTerminateAfterLastWindowClosed:(NSApplication *)sender {
return YES;
}
Copy link
Member

Choose a reason for hiding this comment

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

this seems a little sus to me; does it mean that when the user clicks the exit button on the last remaining window, the app won't get a chance to intercept/handle that event to decide if it wants to shutdown?

Choose a reason for hiding this comment

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

Looks like applicationShouldTerminate() would still be called. But I'm not sure about returning NSTerminateCancel there. Makes it sound like the app couldn't close gracefully.

The terminate() docs look helpful

_insertText_block = insertText_block;
}

- (void)setBlock_magnify:(void (^)(NSEvent *))magnify_block
Copy link
Member

Choose a reason for hiding this comment

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

nice!

[self interpretKeyEvents:@[ event ]];
}

- (void)insertText:(id)string {
Copy link
Member

Choose a reason for hiding this comment

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

I guess we can implement image copy/paste in pixi now too maybe :)

@emidoots emidoots merged commit 860cfb5 into hexops:main Dec 21, 2024
2 checks passed
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.

3 participants