From 1c62190597f45fd606cf680df3f6a099b9f7ec18 Mon Sep 17 00:00:00 2001 From: Pierre Habouzit Date: Thu, 8 Nov 2007 00:07:02 +0100 Subject: [PATCH] LINES - 1 is the status bar, living on stdscr. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit s/main_w/stdscr/ for those… that's probably why I don't see some errors doh Signed-off-by: Pierre Habouzit --- commands.c | 6 +++--- compose.c | 2 +- flags.c | 8 ++++---- init.c | 4 ++-- lib-ui/curs_main.c | 12 ++++++------ lib-ui/layout.c | 2 +- lib-ui/menu.c | 12 ++++++------ muttlib.c | 2 +- recvattach.c | 2 +- recvcmd.c | 4 ++-- 10 files changed, 27 insertions(+), 27 deletions(-) diff --git a/commands.c b/commands.c index 7f64816..7dcb21b 100644 --- a/commands.c +++ b/commands.c @@ -220,12 +220,12 @@ void ci_bounce_message (HEADER * h, int *redraw) if (query_quadoption (OPT_BOUNCE, prompt) != M_YES) { address_list_wipe(&adr); - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); mutt_message (h ? _("Message not bounced.") : _("Messages not bounced.")); return; } - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); rc = mutt_bounce_message (NULL, h, adr); address_list_wipe(&adr); @@ -454,7 +454,7 @@ void mutt_shell_escape (void) if (!buf[0]) m_strcpy(buf, sizeof(buf), mod_core.shell); if (buf[0]) { - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); mutt_endwin (NULL); fflush (stdout); if (mutt_system (buf) != 0 || option (OPTWAITKEY)) diff --git a/compose.c b/compose.c index 70738d5..cb245dc 100644 --- a/compose.c +++ b/compose.c @@ -846,7 +846,7 @@ int mutt_compose_menu (HEADER * msg, /* structure for new message */ int itype; FILE *fp; - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); fname[0] = 0; if (mutt_get_field (_("New file: "), fname, sizeof (fname), M_FILE) != 0 || !fname[0]) diff --git a/flags.c b/flags.c index aca2dcf..137c789 100644 --- a/flags.c +++ b/flags.c @@ -331,17 +331,17 @@ int mutt_change_flag(HEADER * h, int bf) int c; - mvwprintw(main_w, LINES - 1, 0, "%s? (D/N/O/r/*/!): ", + mvwprintw(stdscr, LINES - 1, 0, "%s? (D/N/O/r/*/!): ", bf ? _("Set flag") : _("Clear flag")); - wclrtoeol(main_w); + wclrtoeol(stdscr); c = mutt_getch().ch; if (c == -1) { - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); return (-1); } - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); if (c < 0 || c > countof(actions) || !actions[c]) { BEEP(); diff --git a/init.c b/init.c index aac359d..ce05070 100644 --- a/init.c +++ b/init.c @@ -434,7 +434,7 @@ int query_quadoption2(int v, const char *prompt) default: v = mutt_yesorno(prompt, (v == M_ASKYES)); - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); return (v); } } @@ -450,7 +450,7 @@ int query_quadoption (int opt, const char *prompt) default: v = mutt_yesorno (prompt, (v == M_ASKYES)); - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); return (v); } diff --git a/lib-ui/curs_main.c b/lib-ui/curs_main.c index 6fdbc16..e80d302 100644 --- a/lib-ui/curs_main.c +++ b/lib-ui/curs_main.c @@ -549,13 +549,13 @@ int mutt_index_menu (void) tag = 1; /* give visual indication that the next command is a tag- command */ - mvwaddstr (main_w, LINES - 1, 0, "tag-"); - wclrtoeol (main_w); + mvwaddstr (stdscr, LINES - 1, 0, "tag-"); + wclrtoeol (stdscr); /* get the real command */ if ((op = km_dokey (MENU_MAIN)) == OP_TAG_PREFIX) { /* abort tag sequence */ - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); continue; } } @@ -584,13 +584,13 @@ int mutt_index_menu (void) tag = 1; /* give visual indication that the next command is a tag- command */ - mvwaddstr (main_w, LINES - 1, 0, "tag-"); - wclrtoeol (main_w); + mvwaddstr (stdscr, LINES - 1, 0, "tag-"); + wclrtoeol (stdscr); /* get the real command */ if ((op = km_dokey (MENU_MAIN)) == OP_TAG_PREFIX) { /* abort tag sequence */ - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); continue; } } diff --git a/lib-ui/layout.c b/lib-ui/layout.c index d8e09a4..5dfdb62 100644 --- a/lib-ui/layout.c +++ b/lib-ui/layout.c @@ -59,7 +59,7 @@ void mutt_refresh(void) void mutt_endwin(const char *msg) { if (!option(OPTNOCURSES)) { - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); if (sidebar_w) { delwin(sidebar_w); diff --git a/lib-ui/menu.c b/lib-ui/menu.c index 4c2bf1e..7015ca1 100644 --- a/lib-ui/menu.c +++ b/lib-ui/menu.c @@ -239,9 +239,9 @@ static void menu_redraw_prompt (MUTTMENU * menu) if (*Errorbuf) mutt_clear_error (); - SETCOLOR(main_w, MT_COLOR_NORMAL); - mvwaddstr (main_w, LINES - 1, 0, menu->prompt); - wclrtoeol (main_w); + SETCOLOR(stdscr, MT_COLOR_NORMAL); + mvwaddstr(stdscr, LINES - 1, 0, menu->prompt); + wclrtoeol(stdscr); } } @@ -682,11 +682,11 @@ int mutt_menuLoop (MUTTMENU * menu) i = km_dokey (menu->menu); if (i == OP_TAG_PREFIX || i == OP_TAG_PREFIX_COND) { if (menu->tagged) { - mvwaddstr (main_w, LINES - 1, 0, "Tag-"); - wclrtoeol (main_w); + mvwaddstr(stdscr, LINES - 1, 0, "Tag-"); + wclrtoeol(stdscr); i = km_dokey (menu->menu); menu->tagprefix = 1; - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); } else if (i == OP_TAG_PREFIX) { mutt_error _("No tagged entries."); diff --git a/muttlib.c b/muttlib.c index 338cb01..79fc2c5 100644 --- a/muttlib.c +++ b/muttlib.c @@ -350,7 +350,7 @@ int mutt_save_confirm (const char *s, struct stat *st) } } - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); return (ret); } diff --git a/recvattach.c b/recvattach.c index ac2861d..518cb59 100644 --- a/recvattach.c +++ b/recvattach.c @@ -484,7 +484,7 @@ mutt_query_pipe_attachment(char *command, FILE * fp, BODY * body, int afilter) _("WARNING! You are about to overwrite %s, continue?"), body->filename); if (mutt_yesorno (warning, M_NO) != M_YES) { - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); return; } tempfd = m_tempfd(tfile, sizeof(tfile), NONULL(mod_core.tmpdir), NULL); diff --git a/recvcmd.c b/recvcmd.c index 15858e2..b31fa8a 100644 --- a/recvcmd.c +++ b/recvcmd.c @@ -161,12 +161,12 @@ void mutt_attach_bounce (FILE * fp, HEADER * hdr __attribute__ ((unused)), if (query_quadoption (OPT_BOUNCE, prompt) != M_YES) { address_list_wipe(&adr); - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); mutt_message (p ? _("Message not bounced.") : _("Messages not bounced.")); return; } - CLEARLINE(main_w, LINES - 1); + CLEARLINE(stdscr, LINES - 1); if (cur) ret = mutt_bounce_message (fp, cur->hdr, adr); -- 2.20.1