Issues Minimizing Window on Linux
shadeops opened this issue ยท 3 comments
Howdy,
I noticed some issues when trying to minimize MiniPixel on Linux. (MiniPixel is so awesome I hadn't tried to minimize it before now. ๐ )
Here is a .gif of what happens when the window's minimize button is clicked.
The window loses focus but the immediately seems to un-minimize itself. Additionally if I go to another desktop, I can see it show up in the task bar which generally only happens if an application is trying to get attention.
I have zero SDL experience, but my guess is that the SdlWindow.draw()
call is sees that the window is hidden and tells the window manager to show it:
Lines 261 to 263 in f5f0195
I made a small change here, shadeops@9728a1a, which avoids the SdlWindow.draw()
call entirely if minimized.
Note - This doesn't appear to be a problem with 0.2.1 on Windows.
OS: Kubuntu 20.04
Head: f5f0195
Oh, I never noticed because this issue doesn't show on Gnome:
Screencast from 12.01.2023 22:10:15.webm
It's a bit annoying that KDE conflates the hidden and minimized state of windows. But I guess you can work around that by checking both flags as you did.
IIRC, I added this window unhide mechanism to avoid initially showing a black flash because nothing had been drawn, yet.
I'll try to reproduce this on my Steam Deck. I think it does have KDE. ๐
Yas! That is so amazing. And now I want a Steam Deck!