int nh_poskey(coordxy *x, coordxy *y, int *mod) -- Returns a single character input from the user or a a positioning event (perhaps from a mouse). If the return value is non-zero, a character was typed, else, a position in the MAP window is returned in x, y and mod. mod may be one of
| 1085 | routine always returns a non-zero character. |
| 1086 | */ |
| 1087 | int |
| 1088 | curses_nh_poskey(coordxy *x, coordxy *y, int *mod) |
| 1089 | { |
| 1090 | int key = curses_nhgetch(); |
| 1091 | |
| 1092 | #ifdef NCURSES_MOUSE_VERSION |
| 1093 | /* Mouse event if mouse_support is true */ |
| 1094 | if (key == KEY_MOUSE) { |
| 1095 | key = curses_get_mouse(x, y, mod); |
| 1096 | } |
| 1097 | #else |
| 1098 | nhUse(x); |
| 1099 | nhUse(y); |
| 1100 | nhUse(mod); |
| 1101 | #endif |
| 1102 | |
| 1103 | return key; |
| 1104 | } |
| 1105 | |
| 1106 | /* |
| 1107 | nhbell() -- Beep at user. [This will exist at least until sounds are |
nothing calls this directly
no test coverage detected