Click outside delete item dialog works

This commit is contained in:
Tyfon
2024-06-06 12:04:03 -07:00
parent 3f22ab6eea
commit 583f17153b

View File

@@ -81,8 +81,10 @@ namespace UIFixes
return; return;
} }
// Note the space after firewall, because unity doesn't trim names and BSG is incompetent // Note the space after firewall, because unity doesn't trim names and BSG is incompetent.
Button button = __instance.transform.Find("Window/Firewall ")?.gameObject.GetOrAddComponent<Button>(); // Also for some reason some MessageWindows have a Window child and some don't.
Transform firewall = __instance.transform.Find("Firewall ") ?? __instance.transform.Find("Window/Firewall ");
Button button = firewall?.gameObject.GetOrAddComponent<Button>();
if (button != null) if (button != null)
{ {
button.transition = Selectable.Transition.None; button.transition = Selectable.Transition.None;