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] optional ability to restore app hotkeys #5

Merged

Conversation

nikitatg
Copy link

If app uses hotkeys through hotkey_manager pkg then after meedu player's close/dispose all hotkeys are lost.
There is async callback through which app can re-register it's hotkeys

…otkey_manager pkg) after meedu player's close/dispose
@abdelaziz-mahdy
Copy link
Owner

Why would u want to register the hotkeys after removing them?

Can you explain the situation to me?😅

I don't get why you would need that ?

@nikitatg
Copy link
Author

My use-case is next
App (on windows) provides different functionality (e.g. instant messaging), including own hotkeys. For this I use hotkey_manager HotKeyManager.instance.registerHotkey();
Appearance of video player is only one of functions. When player appears, it registers its hotkeys. And when called MeeduPlayerController.videoPlayerClosed() and/or MeeduPlayerController.dispose() it executes
HotKeyManager.instance.unregisterAll();
This code unregisters any hotkeys in app, including those I registered before I call player.
Easy solution I see is to manually re-register my hotkeys when I close/dispose MeeduPlayerController passing callback

@abdelaziz-mahdy
Copy link
Owner

Oh I get your point now

I may make the hotkey only unregister the video player keys in an update

For now I will merge your request

Thank you for it ❤️

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