Jump to content

Alfred input panel disappears due to background Quit event.


davidj
 Share

Recommended Posts

For a while now, I've had Alfred's input window occasionally disappear when I was in the middle of typing something.  I finally got around to trying to figure out why.  Basically, I can do the following too quickly:

 

1.  Quit an app via cmd-Q

2.  Activate Alfred (in my case, via cmd-space)

3.  Begin typing something

 

If the Alfred panel opens before the background app quits, when that app does finish terminating, the Alfred panel will also close.  The biggest culprit, for me at least, is when I quit Apple's Mail app + Spamsieve.  That combination seems to do enough cleanup prior to closing that I can easily reproduce the behavior I'm talking about.

 

This "bug" is such a minor thing, except when I'm typing in Alfred and the panel suddenly disappears, continued typing is now sent to Finder.  This has occasionally resulted in me renaming files on my desktop, which is super annoying.

 

Anyway, I love Alfred and look forward to seeing it get even better.

 

~~~~~

Alfred v2.8.3 (435)

OS X 10.11.4

Link to comment
Share on other sites

I can kind of reproduce the behaviour when i start an app that takes longer to open and open Alfred then. When the App opened 

it pulls focus and Alfred closes.

This happens when Alfred is set to Compatibility Mode under -> Alfred Preferences -> Appearance -> Options -> Focusing

Change this to "Standard Mode" and check if you still have the problem.

Link to comment
Share on other sites

For a while now, I've had Alfred's input window occasionally disappear when I was in the middle of typing something.  I finally got around to trying to figure out why.  Basically, I can do the following too quickly:

 

 

 

By design, Alfred yields to other apps as, in the vast majority of cases, this is the appropriate behaviour. This is a corner case, where the focus is requested by an app that has taken a long time to launch or quit.

 

We have a ticket to investigate ways to deal with this gracefully, but at this point, your best bet would be to turn on "Show latest history if within 5 minutes" in Alfred's Advanced preferences, so that on the odd occasion where focus is stolen by one of those slow apps, you can simply pop Alfred back up and carry on where you were without having to re-type your query :)

 

I'll move this to closed, but know that we're keeping this in mind. 

 

Cheers,

Vero

Link to comment
Share on other sites

We have a ticket to investigate ways to deal with this gracefully, but at this point, your best bet would be to turn on "Show latest history if within 5 minutes" in Alfred's Advanced preferences, so that on the odd occasion where focus is stolen by one of those slow apps, you can simply pop Alfred back up and carry on where you were without having to re-type your query :)

 

 

Thanks.  As a point of clarification, the issue isn't that I lose what I was typing in Alfred.  It's not as if I get very far anyway.  The issue is as I'm typing, the keyboard input suddenly gets redirected to the Finder, which can make a mess if I don't notice.

Link to comment
Share on other sites

This is a really awkward issue to address, as even if Alfred DIDN'T close (hide) at this point, OS X / Finder would still steal the focus away from him.

 

I'll open a new Apple TSI to ask about this, but I have a previous TSI which was closed a few years back saying nothing could be done in this case.

Link to comment
Share on other sites

could it be possible to have Alfred listening for running applications, and have it showing an alert when active app is closing, such as a large type message before hiding itself?

it would maybe be a good way just to alert the user, on the ( rarely ) situations when such thing happens... 

or maybe I'm simplifying the stuff too much?

Edited by juliosecco
Link to comment
Share on other sites

A possible method, perhaps?

  • Active application switches
  • Before hiding its window, Alfred checks if previously active application is still running
    • If not, then the app probably quit. Alfred stays visible.
    • If it is still running, hide Alfred's window.
I don't know if that's feasible.
Link to comment
Share on other sites

I don't think there is an available fix without a fudge, and seeing as a fix to this would have an intrinsic roll on effect to Alfred's core behaviour (every single time you use him) makes me extremely reluctant to change anything in Alfred with regards to this.

 

Take for example checking running apps, Alfred would have to actually hide to know which app is active as Alfred is the active app when visible (even as a Panel, when OS X shows a different app name in the titlebar). Then Alfred would have to re-show and steal focus by force. This may be unintended behaviour as there are legitimate times when apps launch in the background without stealing focus.

 

Either way, I've raised a developer ticket with Apple, so I'm going to wait and see what they say with this. As Vitor notes, you see the same behaviour with Spotlight so I suspect the real fix to this is in OS X / Finder not stealing focus when an app finishes quitting.

 

Cheers,

Andrew

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...