fix: respect tray icon behavior

This commit is contained in:
nopeless
2023-10-02 14:09:52 -05:00
parent 4509b67ed9
commit a30920ed70
2 changed files with 4 additions and 4 deletions

View File

@@ -213,13 +213,13 @@ namespace GHelper
SetAutoModes(true);
}
public static void SettingsToggle(string action = "")
public static void SettingsToggle(string action = "", bool checkForFocus = false)
{
if (settingsForm.Visible)
{
// If helper window is not on top, this just focuses on the app again
// Pressing the ghelper button again will hide the app
if (!settingsForm.HasAnyFocus())
if (checkForFocus && !settingsForm.HasAnyFocus())
{
settingsForm.ShowAll();
}