boonl@CAEN.ENGIN.UMICH.EDU.UUCP (12/08/86)
Does anybody out there knows how to get back to the display manager while in the GPR borrow mode and return excution of my program in borrow mode when I hit a key? Any help will be appreciated. --boon Lee (boonl@caen.engin.umich.edu)
young-jonathan@YALE.ARPA.UUCP (12/09/86)
Does anybody out there knows how to get back to the display manager while in the GPR borrow mode and return excution of my program in borrow mode when I hit a key? Any help will be appreciated. I use some variation of the procedure below to do this. It doesn't return to your program on any key; the user has to type ^Z to exit the sub-shell. You can do (almost) anything you want to instead of the pgm_$invoke call, though. Waiting for "any key" isn't well defined if you have released the display, but you could wait for any key in your own window... If you have already written procedures to acquire and release the display and to enable and disable events processing, the procedure below should not be hard to fit into your program. --- Jonathan ..decvax!yale!young-jonathan young-jonathan@yale.arpa PROCEDURE Suspend; var ec : ec2_$ptr_t; status : status_$t; begin Save_Cursor; Save_Screen; Disable_Events; Release_Display; writeln ('*** Pushed shell -- do ^Z to get back into <program> ***'); pgm_$invoke ('/com/sh', 7, 0, nil, 0, nil, [pgm_$wait], ec, status); Acquire_Display; Enable_Events; Refresh_Screen; Refresh_Cursor; end;