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

Function askSave

outdated/sys/mac/macmenu.c:1077–1102  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1075}
1076
1077static void
1078askSave()
1079{
1080 Boolean doSave = 1;
1081 Boolean doYes = 0;
1082
1083 if (theMenubar < mbarRegular) {
1084 short itemHit;
1085
1086 ParamText("\pReally Save?", "\p", "\p", "\p");
1087 itemHit = Alert(alrtMenu_NY, (ModalFilterUPP) 0L);
1088 ResetAlertStage();
1089
1090 if (itemHit != bttnMenuAlertYes) {
1091 doSave = 0;
1092 } else {
1093 doYes = 1;
1094 }
1095 }
1096 if (doSave) {
1097 AddToKeyQueue('S', 1);
1098 if (doYes) {
1099 AddToKeyQueue('y', 1);
1100 }
1101 }
1102}
1103
1104static void
1105askQuit()

Callers 1

DoMenuEvtFunction · 0.85

Calls 1

AddToKeyQueueFunction · 0.85

Tested by

no test coverage detected