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

Function dismiss_text

win/X11/wintext.c:86–106  ·  view source on GitHub ↗

* Callback used for all text windows. The window is popped down on any key * or button down event. It is destroyed if the main nethack code is done * with it. */ ARGSUSED*/

Source from the content-addressed store, hash-verified

84 */
85/*ARGSUSED*/
86void
87dismiss_text(Widget w, XEvent *event, String *params, Cardinal *num_params)
88{
89 struct xwindow *wp;
90 struct text_info_t *text_info;
91
92 nhUse(event);
93 nhUse(params);
94 nhUse(num_params);
95
96 wp = find_widget(w);
97 text_info = wp->text_information;
98
99 nh_XtPopdown(wp->popup);
100
101 if (text_info->blocked) {
102 exit_x_event = TRUE;
103 } else if (text_info->destroy_on_ack) {
104 destroy_text_window(wp);
105 }
106}
107
108/* Dismiss when a non-modifier key pressed. */
109void

Callers 2

key_dismiss_textFunction · 0.85
rip_dismiss_textFunction · 0.85

Calls 3

find_widgetFunction · 0.85
nh_XtPopdownFunction · 0.85
destroy_text_windowFunction · 0.85

Tested by

no test coverage detected