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

Validation against system shortcuts doesn't work #141

Closed
PierL opened this issue Nov 29, 2021 · 1 comment
Closed

Validation against system shortcuts doesn't work #141

PierL opened this issue Nov 29, 2021 · 1 comment

Comments

@PierL
Copy link

PierL commented Nov 29, 2021

How does the validation?

In my case, the recorder is allowing all system shortcuts such as cmd+C and cmd+V. I can see the same thing happens with the example app Inspector.

When I use the old version of the framework, which uses the additional PTHotKey framework, I correctly get an error message when I try to set a shortcut that is already taken by the system.

@PierL
Copy link
Author

PierL commented Nov 29, 2021

I figured it out!

I had to link the delegate in the IB and implement the recorder's delegate method - (BOOL)recorderControl:(SRRecorderControl *)aRecorder canRecordShortcut:(SRShortcut *)aShortcut using an instance of SRShortcutValidator to check the shortcut using.

It would be a good idea to include this in the documentation.

@PierL PierL closed this as completed Nov 29, 2021
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

No branches or pull requests

1 participant