-
-
Notifications
You must be signed in to change notification settings - Fork 355
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
Thunderbird and Skim window now showing up in list of windows in AltTab #772
Comments
I can confirm that I've seen this behavour in recent times too, but it's not clearly reproducible (and happened really rarely to me). |
I downloaded Thunderbird, but it always shows in AltTab in my tests. Could you please find steps that reproduce the issue more frequently? I can't reproduce the issue unfortunately Potential duplicate of #639 |
It might well be a duplicate of #639. I have not found a way to reproduce this behavior reliably, it remains stubbornly intermittent. When I submitted this bug, the thunderbird window was in the workspace where it was opened (I use multiple workspaces), I was not connected to an external monitor, and no window was fullscreen. I understand it's hard to debug an issue you can't reproduce. The next time this happens, I will try to trace back what I was doing in or to the missing window before. Since this is not reproducible, is there something I/we can do to help debug once this behavior starts? |
Just saw this behavior for a different app, Skim, the PDF reader. This time the behavior is repeatable, and here's how:
|
@AgilentGCMS I installed Skim, and tried to reproduce, but it's not happening for me. |
@lwouis I just tried doing what you did, i.e., open both files from Finder > Open with > Skim, and indeed AltTab shows both windows. However, can you do the following instead:
On my computer, I'm noticing that this way reproduces the problem, while opening both from Finder does not. |
@lwouis Could you reproduce the behavior? |
@AgilentGCMS I was able to reproduce! That's great! I'll investigate further now on what's happening. Here are the repro steps:
|
The issue seems to be detecting that the window is on the normal level: It seems that the window is initially not on the normal level, right when it spawns, probably due to some macOS animation that's slightly different when opening it from the The reason we look at "is the window on the normal level" is encapsulated in this comment: We need to change the heuristic to handle this better. Either observing changes of that value, as we do for other things like this that change in the first milliseconds of an app launching, or a window opening. Alternatively, we could use a different clever heuristic to help filter out the floating windows. This issue was found, amplified, in Books.app. A potential fix here could also fix #627. |
Possible duplicate of #639 |
I've spend some time trying to find a good heuristic. I can't find anything that could be a proxy to "this window is floating on top of other windows". Especially since it may actually not be true for a few frames during the window creation. The OS is giving us an "incorrect" level for the window for a very short time, before we would get the actual level, but this may reflect an animation or OS glitch where windows spawn at a different level than they end up at. I could see adding a delay before reading the level, but that has obvious downsides. Best would be to observe, but it's a private API, so no way to do that. We could retry on a quick loop (few ms) for a few hundred ms. It has also obvious downsides. |
I should say that while the thunderbird issue is not as easily reproducible, when it does occur it's fairly stubborn in staying. E.g., right now I have Brave browser and thunderbird open (two windows), and even though Thunderbird is in the foreground and above Brave, AltTab is not showing Thunderbird. I can even minimize Brave at this point, and AltTab will still not show Thunderbird. The only fix I've found is to quit and then restart AltTab, then the thunderbird windows show up. |
I can't reproduce the issue with Thunderbird, and same goes for other reports in #639. The only thing i could reproduce and thus investigate is with Skim. It may be that every other case is stemming from the same root cause: window level (windows being on top of others) changing right when a window is created. It would explain why AltTab recognizes missing windows after a restart, as these would then be stable with the correct level. it could also be that these other scenarios have other root causes. No way to know until i can reproduce and investigate them. For now, the only thing i could investigate is tricky. I've written above how i don't have a way right now to avoid the issue. That's why i tagged this ticket with the "need breakthrough" label which i use when i'm hoping someone could step in and help with a clever idea or even better share code directly. |
@AgilentGCMS @mfn This ticket was closed automatically when I tagged it in some commits. I'd like to clarify the status to you: the bug in Skim should be fixed. I can no longer reproduce it locally. Could you please let me know if it's fixed for you as well? Regarding Thunderbird, please also let me know. I couldn't reproduce the issue previously, so I rely on you to tell me if the issue is indeed gone or not 👍 |
Thanks for the ping, don't recall having seen this recently 🤞 |
Describe the bug
I have three windows from three different apps open on my current workspace, geany (a code editor), iTerm2 (terminal), and thunderbird (email client). I have AltTab set up to display all apps from visible spaces upon Cmd+Tab. However, when I hit Cmd+Tab, thunderbird does not show in the thumbnails. I've taken a screenshot right after hitting Cmd+Tab and before releasing Cmd. You can see all three windows, i.e., none of them are hidden or minimized, yet the AltTab thumbnails on top only contain two.
Steps to reproduce the bug
Note: This is not 100% reproducible. Sometimes AltTab does show a thumbnail for thunderbird. However, once it starts to not show the thunderbird thumbnail, the only fix is to quit and restart thunderbird. I have not checked if this bug exists for other apps, I'm reporting for thunderbird because that's where I first noticed it.
The text was updated successfully, but these errors were encountered: