From f55217a4f485e39c84b3558cba463d9df6815066 Mon Sep 17 00:00:00 2001 From: Leonardo Emanuele Date: Sat, 1 Jun 2024 18:08:40 +0200 Subject: [PATCH] C# UIMenu added a `OnFilteringFailed` event called on erroring. --- ScaleformUI_Csharp/Menus/UIMenu/UIMenu.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ScaleformUI_Csharp/Menus/UIMenu/UIMenu.cs b/ScaleformUI_Csharp/Menus/UIMenu/UIMenu.cs index cce26d91..36a965cc 100644 --- a/ScaleformUI_Csharp/Menus/UIMenu/UIMenu.cs +++ b/ScaleformUI_Csharp/Menus/UIMenu/UIMenu.cs @@ -813,6 +813,7 @@ public enum Keys public delegate void MenuOpenedEvent(UIMenu menu, dynamic data = null); public delegate void MenuClosedEvent(UIMenu menu); public delegate void ItemHighlightedEvent(UIMenu menu, UIMenuItem item); + public delegate void MenuFilteringFailedEvent(UIMenu menu); public enum MenuAnimationType { @@ -1101,6 +1102,7 @@ public ItemFont DescriptionFont public event MenuOpenedEvent OnMenuOpen; public event MenuClosedEvent OnMenuClose; + public event MenuFilteringFailedEvent OnFilteringFailed; /// /// Called every time a Stat item changes value @@ -2622,6 +2624,7 @@ public void FilterMenuItems(Func predicate) catch (Exception ex) { Debug.WriteLine("^1ScaleformUI - " + ex.ToString()); + OnFilteringFailed?.Invoke(this); } }