MCPcopy Index your code
hub / github.com/NetHack/NetHack / map_menu_cmd

Function map_menu_cmd

src/options.c:8110–8121  ·  view source on GitHub ↗

* Map the given character to its corresponding menu command. If it * doesn't match anything, just return the original. */

Source from the content-addressed store, hash-verified

8108 * doesn't match anything, just return the original.
8109 */
8110char
8111map_menu_cmd(char ch)
8112{
8113 char *found = strchr(gm.mapped_menu_cmds, ch);
8114
8115 if (found) {
8116 int idx = (int) (found - gm.mapped_menu_cmds);
8117
8118 ch = gm.mapped_menu_op[idx];
8119 }
8120 return ch;
8121}
8122
8123/* get keystrokes that are used for menu scrolling operations which apply;
8124 printable: for use in a prompt, non-printable: for yn_function() choices */

Callers 8

process_menu_windowFunction · 0.85
curs_scroll_invtFunction · 0.85
menu_get_selectionsFunction · 0.85
menu_keyFunction · 0.85
DoMenuScrollFunction · 0.85
SelectMenuMethod · 0.85
mac_select_menuFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected