MCPcopy Create free account
hub / github.com/NetHack/NetHack / mswin_start_menu

Function mswin_start_menu

outdated/sys/wince/mswproc.c:1006–1023  ·  view source on GitHub ↗

Start using window as a menu. You must call start_menu() before add_menu(). After calling start_menu() you may not putstr() to the window. Only windows of type NHW_MENU may be used for menus. */

Source from the content-addressed store, hash-verified

1004 be used for menus.
1005*/
1006void
1007mswin_start_menu(winid wid, unsigned long mbehavior)
1008{
1009 logDebug("mswin_start_menu(%d, %lu)\n", wid, mbehavior);
1010 if ((wid >= 0) && (wid < MAXWINDOWS)) {
1011 if (GetNHApp()->windowlist[wid].win == NULL
1012 && GetNHApp()->windowlist[wid].type == NHW_MENU) {
1013 GetNHApp()->windowlist[wid].win =
1014 mswin_init_menu_window(MENU_TYPE_MENU);
1015 GetNHApp()->windowlist[wid].dead = 0;
1016 }
1017
1018 if (GetNHApp()->windowlist[wid].win != NULL) {
1019 SendMessage(GetNHApp()->windowlist[wid].win, WM_MSNH_COMMAND,
1020 (WPARAM) MSNH_MSG_STARTMENU, (LPARAM) NULL);
1021 }
1022 }
1023}
1024
1025/*
1026add_menu(windid window, int glyph, const anything identifier,

Callers 1

ActivateCellFunction · 0.70

Calls 3

logDebugFunction · 0.70
GetNHAppFunction · 0.70
mswin_init_menu_windowFunction · 0.70

Tested by

no test coverage detected