From e106151072e9d0a7973427cb402b205b1afd3760 Mon Sep 17 00:00:00 2001 From: Sergey Lyubka Date: Tue, 26 Nov 2013 22:17:29 +0000 Subject: [PATCH] Showing port number on mongoose icon context menu --- build/main.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/build/main.c b/build/main.c index 48ca3eb8..1694dcda 100644 --- a/build/main.c +++ b/build/main.c @@ -822,7 +822,9 @@ static LRESULT CALLBACK WindowProc(HWND hWnd, UINT msg, WPARAM wParam, AppendMenu(hMenu, MF_STRING | (!service_installed ? MF_GRAYED : 0), ID_REMOVE_SERVICE, "Deinstall service"); AppendMenu(hMenu, MF_SEPARATOR, ID_SEPARATOR, ""); - AppendMenu(hMenu, MF_STRING, ID_CONNECT, "Start browser"); + snprintf(buf, sizeof(buf), "Start browser on port %s", + mg_get_option(ctx, "listening_ports")); + AppendMenu(hMenu, MF_STRING, ID_CONNECT, buf); AppendMenu(hMenu, MF_STRING, ID_SETTINGS, "Edit Settings"); AppendMenu(hMenu, MF_SEPARATOR, ID_SEPARATOR, ""); AppendMenu(hMenu, MF_STRING, ID_QUIT, "Exit");