From 69a3dbade7c75427d2c8df66eeb44415e8bd0db8 Mon Sep 17 00:00:00 2001 From: Thomas Roessler Date: Mon, 5 Oct 1998 18:42:56 +0000 Subject: [PATCH] Some fixes to the macro-function patch. --- compose.c | 23 +++++++++++++---------- flags.c | 2 +- 2 files changed, 14 insertions(+), 11 deletions(-) diff --git a/compose.c b/compose.c index 40bb49276..263bedc5b 100644 --- a/compose.c +++ b/compose.c @@ -85,7 +85,7 @@ void snd_entry (char *b, size_t blen, MUTTMENU *menu, int num) static int pgp_send_menu (int bits) { - int c; + event_t ch; char *p; char *micalg = NULL; char input_signas[SHORT_STRING]; @@ -99,9 +99,12 @@ static int pgp_send_menu (int bits) do { mutt_refresh (); - if ((c = mutt_getch ()) == ERR) + + ch = mutt_getch(); + if (ch.ch == EOF) break; - if (c == 'a') + + if (ch.ch == 'a') { unset_option(OPTPGPCHECKTRUST); @@ -136,7 +139,7 @@ static int pgp_send_menu (int bits) mutt_error _("An unkown PGP version was defined for signing."); } } - else if (c == 'm') + else if (ch.ch == 'm') { if(!(bits & PGPSIGN)) mutt_error _("This doesn't make sense if you don't want to sign the message."); @@ -160,21 +163,21 @@ static int pgp_send_menu (int bits) } } } - else if (c == 'e') + else if (ch.ch == 'e') bits |= PGPENCRYPT; - else if (c == 's') + else if (ch.ch == 's') bits |= PGPSIGN; - else if (c == 'b') + else if (ch.ch == 'b') bits = PGPENCRYPT | PGPSIGN; - else if (c == 'f') + else if (ch.ch == 'f') bits = 0; else { BEEP (); - c = 0; + ch.ch = 0; } } - while (c == 0); + while (ch.ch == 0); CLEARLINE (LINES-1); mutt_refresh (); return (bits); diff --git a/flags.c b/flags.c index b53f2c180..3ea6c44a9 100644 --- a/flags.c +++ b/flags.c @@ -252,7 +252,7 @@ int mutt_change_flag (HEADER *h, int bf) int i, flag; event_t event; - mvprintw (LINES - 1, 0, "%s flag? (D/N/O/r/*/!): ", bf ? _("Set") : _("Clear")); + mvprintw (LINES - 1, 0, "%s? (D/N/O/r/*/!): ", bf ? _("Set flag") : _("Clear flag")); clrtoeol (); event = mutt_getch(); -- 2.40.0