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

Prevent an exception from being thrown #2205

merged 1 commit into from May 10, 2016

Prevent an exception from being thrown #2205

merged 1 commit into from May 10, 2016


Copy link

@mattbeshara mattbeshara commented May 8, 2016

I recently noticed some exceptions in my system log originating from QS. I've put a few examples in a gist:

The cause seems to be that sometimes when I have the search window open, QS isn't getting the type of NSEvent it expects from [NSApp currentEvent]. A couple of "SysDefined" events sometimes occur where the code only expects either NSKeyDown or NSKeyUp events. I don't know what those unexpected events are, what triggers them, or when they occur, so I don't know how to reproduce this for those specific events. The code checks that the function key is held down before calling [NSEvent isARepeat], but I don't know what relationship that may have with the non-key events it's getting.

Getting the exception thrown is reproducible though, by causing another kind of unhandled event to occur. Open the search window, type a letter to cause an object to appear in the first pane if there isn't one there already, position the mouse cursor over the icon in the first pane, hold the function key, and scroll with a mouse or trackpad.

To prevent that exception from being thrown, this patch checks that an event is a valid key event before calling isARepeat on it.

…ayed and QS receives a non-key event at the wrong time
Copy link

@HenningJ HenningJ commented May 8, 2016

Can one of the admins verify this patch?

Copy link

@skurfer skurfer commented May 10, 2016

This looks good. Thanks!

The real solution is to remove the ability to automatically show children altogether. I had a branch that did that, but we also wanted to update the NIB to use AutoLayout and couldn’t get it right.

@skurfer skurfer merged commit eadf20f into quicksilver:master May 10, 2016
1 check passed
skurfer added a commit that referenced this issue May 10, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
None yet

Successfully merging this pull request may close these issues.

None yet

3 participants