jcs
/amend
/amendments
/94
main: Add missing glue to make Desk Accessories work
jcs made amendment 94 over 2 years ago
--- main.c Wed Aug 31 16:29:19 2022
+++ main.c Tue Sep 6 13:38:23 2022
@@ -25,7 +25,7 @@
#include "settings.h"
#include "util.h"
-MenuHandle file_menu, edit_menu, repo_menu, amendment_menu;
+MenuHandle apple_menu, file_menu, edit_menu, repo_menu, amendment_menu;
Handle amendment_list_ldef_h;
bool quitting = false;
@@ -35,7 +35,6 @@ int
main(void)
{
Handle mbar;
- MenuHandle apple_menu;
EventRecord event;
WindowPtr event_win;
GrafPtr old_port;
@@ -228,6 +227,16 @@ handle_menu(long menu_id)
note("%s", vers_s);
} else
warnx("Can't find version number!");
+ break;
+ }
+ default: {
+ Str255 da;
+ GrafPtr save_port;
+
+ GetItem(apple_menu, LoWord(menu_id), &da);
+ GetPort(&save_port);
+ OpenDeskAcc(da);
+ SetPort(save_port);
break;
}
}