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

Method qt_nh_poskey

outdated/win/Qt3/qt3_win.cpp:4918–4944  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4916}
4917
4918int NetHackQtBind::qt_nh_poskey(int *x, int *y, int *mod)
4919{
4920 if (main)
4921 main->fadeHighlighting();
4922
4923 // Process events until a key or map-click arrives.
4924 //
4925 while (keybuffer.Empty() && clickbuffer.Empty()
4926#ifdef SAFERHANGUP
4927 && !program_state.done_hup
4928#endif
4929 ) {
4930 qApp->enter_loop();
4931 }
4932#ifdef SAFERHANGUP
4933 if (program_state.done_hup && keybuffer.Empty()) return '\033';
4934#endif
4935 if (!keybuffer.Empty()) {
4936 return keybuffer.GetAscii();
4937 } else {
4938 *x=clickbuffer.NextX();
4939 *y=clickbuffer.NextY();
4940 *mod=clickbuffer.NextMod();
4941 clickbuffer.Get();
4942 return 0;
4943 }
4944}
4945
4946void NetHackQtBind::qt_nhbell()
4947{

Callers

nothing calls this directly

Calls 7

fadeHighlightingMethod · 0.45
EmptyMethod · 0.45
GetAsciiMethod · 0.45
NextXMethod · 0.45
NextYMethod · 0.45
NextModMethod · 0.45
GetMethod · 0.45

Tested by

no test coverage detected