summaryrefslogtreecommitdiff
path: root/usr.bin/mg/keymap.c
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>2000-03-03 19:31:28 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>2000-03-03 19:31:28 +0000
commit30e5ddef47f541d6e3c5429a6f3a9320d075a546 (patch)
treeaff1e907b125a17f59b2e2168730be1c19ececfb /usr.bin/mg/keymap.c
parentdde7d8db2f17fec2ee7e5955fda9c20b0721cbc7 (diff)
Reverse rutgers change (attachtoparent vs. spawncli)
New ttreinit function that enters application mode, enables the keypad and resets the tty size. New spawn module that calls tttidy() to exit application mode (and cleanup) then calls ttreinit() after resume to get back into application mode. Assumes we have job control. This takes advantage of the xterm 'alternate screen'.
Diffstat (limited to 'usr.bin/mg/keymap.c')
-rw-r--r--usr.bin/mg/keymap.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/usr.bin/mg/keymap.c b/usr.bin/mg/keymap.c
index d880bce016d..69c34e300e3 100644
--- a/usr.bin/mg/keymap.c
+++ b/usr.bin/mg/keymap.c
@@ -218,7 +218,9 @@ extern int queryrepl(); /* Query replace */
* Defined by "spawn.c".
*/
extern int spawncli(); /* Run CLI in a subjob. */
+#ifdef VMS
extern int attachtoparent(); /* Attach to parent process */
+#endif
/* defined by "version.c" */
@@ -584,7 +586,11 @@ static PF fund_CJ[] = {
killregion, /* ^W */
prefix, /* ^X */
yank, /* ^Y */
+#ifndef VMS
+ spawncli, /* ^Z */
+#else
attachtoparent, /* ^Z */
+#endif
};
static PF fund_esc[] = {
prefix, /* esc */
@@ -712,7 +718,11 @@ static PF diredcl[] = {
prefix, /* ^X */
};
static PF diredcz[] = {
+#ifndef VMS
+ spawncli, /* ^Z */
+#else
attachtoparent, /* ^Z */
+#endif
prefix, /* esc */
rescan, /* ^\ */
rescan, /* ^] */
@@ -1071,7 +1081,11 @@ FUNCTNAMES functnames[] = {
#ifndef NO_MACRO
{definemacro, "start-kbd-macro"},
#endif
+#ifdef VMS
{attachtoparent,"suspend-emacs"},
+#else
+ {spawncli, "suspend-emacs"},
+#endif
{usebuffer, "switch-to-buffer"},
{poptobuffer, "switch-to-buffer-other-window"},
{twiddle, "transpose-chars"},