Hi Fabian,Yes, this only hides the tray when it should. The code only happens on the WM_DISPLAYCHANGE event, which occurs on resolution changes. I wouldn't write any code that would damage any existing features.While the resolutions shouldn't differ, actually the SM_CYFULLSCREEN reports a larger dimension by 11. What happens is beforehand, the systray was getting drawn no matter what on a resolution update. This patch checks if the current foreground game is covering the entire screen, hence covering the area where the systray would normally be drawn, which is also the entire desktop resolution, and if it is, does not draw the systray.I tested this patch thoroughly and it only enhances existing functionality.Thanks in Advance,HamishOn Sun, Dec 30, 2018 at 10:44 AM Fabian Maurer <dark.shadow4@web.de> wrote:Hi Hamish,
> if ( !( GetSystemMetrics(SM_CXFULLSCREEN) >= GetSystemMetrics(SM_CXSCREEN)
> && GetSystemMetrics(SM_CYFULLSCREEN) >= GetSystemMetrics(SM_CYSCREEN) ))
Why are you comparing two system metrics? Are they changing when a program goes fullscreen? I'm pretty sure they don't.
Did you also test that it only hides the taskbar when it should? For me both SM_CXSCREEN and SM_CXFULLSCREEN are 1920 - that would hide the tray always, even in windowed mode.
Regards,
Fabian Maurer