From fa080de7afc95aa1c19a6e6fc0e0708ced2eadc4 Mon Sep 17 00:00:00 2001 From: Joseph Hunkeler Date: Wed, 8 Jul 2015 20:46:52 -0400 Subject: Initial commit --- sys/gio/gpagefile.x | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 sys/gio/gpagefile.x (limited to 'sys/gio/gpagefile.x') diff --git a/sys/gio/gpagefile.x b/sys/gio/gpagefile.x new file mode 100644 index 00000000..df950e71 --- /dev/null +++ b/sys/gio/gpagefile.x @@ -0,0 +1,29 @@ +# Copyright(c) 1986 Association of Universities for Research in Astronomy Inc. + +include +include +include + +# GPAGEFILE -- File pager which works in or out of cursor mode. If in graphics +# mode, the workstation is deactivated, the file paged, and graphics mode later +# restored. + +procedure gpagefile (gp, fname, prompt) + +pointer gp # graphics descriptor +char fname[ARB] # name of file to be paged +char prompt[ARB] # user prompt string + +bool wsactive +int and() + +begin + wsactive = (and (GP_GFLAGS(gp), GF_WSACTIVE) != 0) + + if (wsactive) + call gdeactivate (gp, 0) + iferr (call pagefile (fname, prompt)) + call erract (EA_WARN) + if (wsactive) + call greactivate (gp, AW_PAUSE) +end -- cgit