From 43baeb2306eec0170a90d69bd60eea13ac622f2f Mon Sep 17 00:00:00 2001 From: Evgeny Date: Tue, 2 Jun 2026 22:13:18 +0300 Subject: [PATCH] etcpmon: fix autoradio button groups and add missing ETCPROUTE category --- tools/etcpmon/etcpmon_gui.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/tools/etcpmon/etcpmon_gui.c b/tools/etcpmon/etcpmon_gui.c index 1105ac64..2e956d53 100644 --- a/tools/etcpmon/etcpmon_gui.c +++ b/tools/etcpmon/etcpmon_gui.c @@ -744,7 +744,7 @@ static void CreateControls(struct etcpmon_app* app) { "UASYNC","LL_QUEUE","CONNECTION","ETCP","CRYPTO", "MEMORY","TIMING","CONFIG","TUN","ROUTING", "TIMERS","NORMALIZER","BGP","SOCKET","CONTROL", - "DUMP","TRAFFIC","DEBUG_CAT","GENERAL","NAT","KEEPALIVE" + "DUMP","TRAFFIC","DEBUG_CAT","GENERAL","NAT","KEEPALIVE","ETCPROUTE" }; int ncat = sizeof(cat_names) / sizeof(cat_names[0]); app->debug_cat_count = ncat; @@ -753,9 +753,10 @@ static void CreateControls(struct etcpmon_app* app) { 1015, dy + 2, 55, 20, hWnd, (HMENU)IDC_STATIC, hInst, NULL); for (int l = 0; l < 6; l++) { int lx = 1080 + l * 22; + DWORD style = WS_CHILD | WS_VISIBLE | BS_AUTORADIOBUTTON; + if (l == 0) style |= WS_GROUP; app->hDebugGlobalRadio[l] = CreateWindowExA(0, "BUTTON", "", - WS_CHILD | WS_VISIBLE | BS_AUTORADIOBUTTON, - lx, dy, 20, 20, hWnd, (HMENU)(UINT_PTR)(IDC_DEBUG_GLOBAL_BASE + l), hInst, NULL); + style, lx, dy, 20, 20, hWnd, (HMENU)(UINT_PTR)(IDC_DEBUG_GLOBAL_BASE + l), hInst, NULL); } dy += 22; @@ -773,9 +774,10 @@ static void CreateControls(struct etcpmon_app* app) { 1015, dy + 1, 60, 16, hWnd, (HMENU)(UINT_PTR)(IDC_DEBUG_NAME_BASE + r), hInst, NULL); for (int l = 0; l < 6; l++) { int lx = 1080 + l * 22; + DWORD style = WS_CHILD | WS_VISIBLE | BS_AUTORADIOBUTTON; + if (l == 0) style |= WS_GROUP; app->hDebugCatRadio[r][l] = CreateWindowExA(0, "BUTTON", "", - WS_CHILD | WS_VISIBLE | BS_AUTORADIOBUTTON, - lx, dy, 20, 16, hWnd, (HMENU)(UINT_PTR)(IDC_DEBUG_ROW_BASE + r * 8 + l), hInst, NULL); + style, lx, dy, 20, 16, hWnd, (HMENU)(UINT_PTR)(IDC_DEBUG_ROW_BASE + r * 8 + l), hInst, NULL); } dy += 18; }