From 8538869d11c8d55d2de3c1467badb044f18dc3d1 Mon Sep 17 00:00:00 2001 From: Javier Nonis Date: Sat, 3 Aug 2024 00:24:45 -0300 Subject: [PATCH] Fix for FX UI --- src/uimenu.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/uimenu.cpp b/src/uimenu.cpp index b367db7..431ba9e 100644 --- a/src/uimenu.cpp +++ b/src/uimenu.cpp @@ -3002,9 +3002,11 @@ CUIMenu::TMenuItem* CUIMenu::getInsertFXMenuItem(unsigned type) { CUIMenu::TMenuItem* menu = getFXMenuItem(type); - for (size_t i = 0; i < sizeof(menu); i++) + unsigned i = 0; + while(menu[i].Name != NULL) { menu[i].Handler = EditTGFXParameter; + i++; } return menu; @@ -3014,9 +3016,11 @@ CUIMenu::TMenuItem* CUIMenu::getSendFXMenuItem(unsigned type) { CUIMenu::TMenuItem* menu = getFXMenuItem(type); - for (size_t i = 0; i < sizeof(menu); i++) + unsigned i = 0; + while(menu[i].Name != NULL) { menu[i].Handler = EditSendFXParameter; + i++; } return menu;