diff -r fbdfaacc4182 -r f154867f54dc ui/common/menu.c --- a/ui/common/menu.c Sat Jan 27 17:50:19 2024 +0100 +++ b/ui/common/menu.c Sun Jan 28 16:31:34 2024 +0100 @@ -211,7 +211,7 @@ UiMenuItemList* item = malloc(sizeof(UiMenuItemList)); item->item.prev = NULL; item->item.next = NULL; - item->item.type = UI_MENU_ITEM_LIST; + item->item.type = UI_MENU_CHECKITEM_LIST; item->callback = args.onselect; item->userdata = args.onselectdata; item->varname = nl_strdup(args.varname); @@ -227,7 +227,7 @@ UiMenuItemList* item = malloc(sizeof(UiMenuItemList)); item->item.prev = NULL; item->item.next = NULL; - item->item.type = UI_MENU_ITEM_LIST; + item->item.type = UI_MENU_RADIOITEM_LIST; item->callback = args.onselect; item->userdata = args.onselectdata; item->varname = nl_strdup(args.varname); @@ -237,6 +237,10 @@ void uic_add_menu_to_stack(UiMenu* menu) { + if (!current) { + current = cxLinkedListCreate(cxDefaultAllocator, NULL, CX_STORE_POINTERS); + } + cxListInsert(current, 0, menu); }