-
Notifications
You must be signed in to change notification settings - Fork 114
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
Activating SRRecorderControl #13
Comments
Have you checked code in the demo? Could you attach sample project? |
I'm just calling [self.srRecorderEditKeyboardShortcut setAllowedModifierFlags:NSShiftKeyMask | NSAlternateKeyMask | NSCommandKeyMask
requiredModifierFlags:0
allowsEmptyModifierFlags:NO]; whereas srRecorderEditKeyboardShortcut is the IBOutlet of my custom view SRRecorderControl. SRRecorderControl's delegate and file owner is set to my window controller, where I call the above code. What am I missing? |
This looks right. The problem is somewhere else. Could you create a demo project and try to reproduce the issue? |
Hm... I created a new test project, did the same things as I did in my main project, and it suddenly works... I have no idea what I've done wrong in my main... Edit: After playing around some more, it seems that the problem arrises from me loading the SRRecorderControl in a sheet instead of in the main window. Once I move it over to the main window, it works fine. What would be preventing it from working with the sheet? |
I would be able to answer If you provide demo project that demonstrates the issue |
Here you go. Took a bit to remove all of the fluff from the app. |
Ok, I was able to reproduce the issue. It's not related to SR, but some strange behavior of title-less NSWindow (and NSPanel): if you add NSTextField to the PreferenceWindow, you'll find that it won't be made first responder. The "workaround" is to enable Title Bar option in IB. Since it's sheet window, title won't be shown anyway, but this option somehow affects ability of the window to become key. |
Thank you very much. That fixed it. That is a rather weird "feature" (bug?). |
The ability to specify title bar was introduced recently and I didn't have chance to play with it yet. |
I set up the frameworks after a bit of work and added a custom view with the class of SRRecorderControl, but now when I click on the control, nothing happens. It doesn't start to capture key commands, nor does it call anything (to my knowledge). What am I doing wrong?
The text was updated successfully, but these errors were encountered: