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

Add the input module for the plugin system #4569

Merged
merged 4 commits into from
Aug 14, 2023
Merged

Add the input module for the plugin system #4569

merged 4 commits into from
Aug 14, 2023

Conversation

lhc70000
Copy link
Member

@lhc70000 lhc70000 commented Aug 8, 2023


Description:

One of the two remaining API modules to be added in IINA 1.4.0. The other one would be a method to communicate with external programs (I'm considering WebSocket).

Please see the documentation for this module at: https://docs.iina.io/interfaces/IINA.API.Input.

This PR also contains a fix to a regression added in #4464.

The ultimate goal for this module is to let the plugin have the opportunity to accept and intercept various input events. However, much work needs to be done if we want to fully support that.

The implementation contained in this PR only allows users to intercept keyDown and keyUp events passed to the main window, and listen to the mouseUp events. This is already enough for features like "hold to seek" or "hold to speedup". We hope to add more functions in the future, but that requires some serious effort.

Please feel free to comment about the API design.

@lhc70000 lhc70000 merged commit 06be87a into develop Aug 14, 2023
1 check passed
@lhc70000 lhc70000 deleted the plugin-input branch August 14, 2023 19:23
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.

1 participant