From d240531be8ae2e28fed82a256e72ba449339540d Mon Sep 17 00:00:00 2001 From: Pierre Habouzit Date: Wed, 7 Nov 2007 23:57:53 +0100 Subject: [PATCH] Simplifications. Signed-off-by: Pierre Habouzit --- compose.c | 3 +-- lib-ui/menu.c | 6 +++--- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/compose.c b/compose.c index d36008b..70738d5 100644 --- a/compose.c +++ b/compose.c @@ -1048,8 +1048,7 @@ int mutt_compose_menu (HEADER * msg, /* structure for new message */ compose_status_line (buf, sizeof (buf), menu, NONULL (ComposeFormat)); CLEARLINE(main_w, 0); SETCOLOR(main_w, MT_COLOR_STATUS); - wmove (main_w, 0, 0); - wprintw (main_w, "%-*.*s", getmaxx(main_w), getmaxx(main_w), buf); + mvwprintw (main_w, 0, 0, "%-*.*s", getmaxx(main_w), getmaxx(main_w), buf); SETCOLOR(main_w, MT_COLOR_NORMAL); menu->redraw &= ~REDRAW_STATUS; } diff --git a/lib-ui/menu.c b/lib-ui/menu.c index f3ca7c5..4c2bf1e 100644 --- a/lib-ui/menu.c +++ b/lib-ui/menu.c @@ -180,12 +180,12 @@ void menu_redraw_motion (MUTTMENU * menu) return; } - wmove (main_w, menu->oldcurrent + menu->offset - menu->top, 0); SETCOLOR(main_w, MT_COLOR_NORMAL); BKGDSET(main_w, MT_COLOR_NORMAL); /* erase the current indicator */ - wattrset (main_w, menu->color (menu->oldcurrent)); + wattrset(main_w, menu->color(menu->oldcurrent)); + wmove (main_w, menu->oldcurrent + menu->offset - menu->top, 0); wclrtoeol (main_w); menu_make_entry (buf, sizeof (buf), menu, menu->oldcurrent); menu_pad_string (buf, sizeof (buf)); @@ -212,13 +212,13 @@ void menu_redraw_current (MUTTMENU * menu) { char buf[STRING]; - wmove (main_w, menu->current + menu->offset - menu->top, 0); menu_make_entry (buf, sizeof (buf), menu, menu->current); menu_pad_string (buf, sizeof (buf)); wattrset (main_w, menu->color (menu->current)); ADDCOLOR(main_w, MT_COLOR_INDICATOR); BKGDSET(main_w, MT_COLOR_INDICATOR); + wmove (main_w, menu->current + menu->offset - menu->top, 0); wclrtoeol (main_w); print_enriched_string (menu->color (menu->current), (unsigned char *) buf, 0); -- 2.20.1