fixed (?) bug reported by Andreas Kneib.
git-svn-id: svn://svn.berlios.de/mutt-ng/trunk@34
e385b8ad-14ed-0310-8656-
cc95a2468c6d
#define REDRAW_FULL (1<<5)
#define REDRAW_BODY (1<<6)
#define REDRAW_SIGWINCH (1<<7)
#define REDRAW_FULL (1<<5)
#define REDRAW_BODY (1<<6)
#define REDRAW_SIGWINCH (1<<7)
+#define REDRAW_SIDEBAR (1<<8)
#define M_MODEFMT "-- Mutt: %s"
#define M_MODEFMT "-- Mutt: %s"
j = -1;
while (display_line (fp, &last_pos, &lineInfo, ++i, &lastLine, &maxLine,
has_types | SearchFlag, &QuoteList, &q_level, &force_redraw,
j = -1;
while (display_line (fp, &last_pos, &lineInfo, ++i, &lastLine, &maxLine,
has_types | SearchFlag, &QuoteList, &q_level, &force_redraw,
- &SearchRE) == 0)
- if (!lineInfo[i].continuation && ++j == lines)
- {
- topline = i;
- if (!SearchFlag)
- break;
- }
+ &SearchRE) == 0) {
+ if (!lineInfo[i].continuation && ++j == lines)
+ {
+ topline = i;
+ if (!SearchFlag)
+ break;
+ }
+ redraw |= REDRAW_SIDEBAR;
+ } /* while */
}
if ((redraw & REDRAW_BODY) || topline != oldtopline)
}
if ((redraw & REDRAW_BODY) || topline != oldtopline)
lines++;
curline++;
move(lines + bodyoffset, SidebarWidth);
lines++;
curline++;
move(lines + bodyoffset, SidebarWidth);
+ redraw |= REDRAW_SIDEBAR;
}
last_offset = lineInfo[curline].offset;
} while (force_redraw);
}
last_offset = lineInfo[curline].offset;
} while (force_redraw);
SETCOLOR (MT_COLOR_NORMAL);
}
SETCOLOR (MT_COLOR_NORMAL);
}
+ if (redraw & REDRAW_SIDEBAR)
+ draw_sidebar(MENU_PAGER);
+
if ((redraw & REDRAW_INDEX) && index)
{
/* redraw the pager_index indicator, because the
if ((redraw & REDRAW_INDEX) && index)
{
/* redraw the pager_index indicator, because the
while (display_line (fp, &last_pos, &lineInfo, i, &lastLine,
&maxLine, M_SEARCH | (flags & M_PAGER_NSKIP),
&QuoteList, &q_level,
while (display_line (fp, &last_pos, &lineInfo, i, &lastLine,
&maxLine, M_SEARCH | (flags & M_PAGER_NSKIP),
&QuoteList, &q_level,
- &force_redraw, &SearchRE) == 0)
+ &force_redraw, &SearchRE) == 0) {
+ redraw |= REDRAW_SIDEBAR;
+ }
(0 == (dretval = display_line (fp, &last_pos, &lineInfo,
new_topline, &lastLine, &maxLine, M_TYPES,
&QuoteList, &q_level, &force_redraw, &SearchRE))))
(0 == (dretval = display_line (fp, &last_pos, &lineInfo,
new_topline, &lastLine, &maxLine, M_TYPES,
&QuoteList, &q_level, &force_redraw, &SearchRE))))
- && lineInfo[new_topline].type != MT_COLOR_QUOTED)
+ && lineInfo[new_topline].type != MT_COLOR_QUOTED) {
+ redraw |= REDRAW_SIDEBAR;
(0 == (dretval = display_line (fp, &last_pos, &lineInfo,
new_topline, &lastLine, &maxLine, M_TYPES,
&QuoteList, &q_level, &force_redraw, &SearchRE))))
(0 == (dretval = display_line (fp, &last_pos, &lineInfo,
new_topline, &lastLine, &maxLine, M_TYPES,
&QuoteList, &q_level, &force_redraw, &SearchRE))))
- && lineInfo[new_topline].type == MT_COLOR_QUOTED)
+ && lineInfo[new_topline].type == MT_COLOR_QUOTED) {
+ redraw |= REDRAW_SIDEBAR;
+ }
while (display_line (fp, &last_pos, &lineInfo, i, &lastLine,
&maxLine, has_types,
&QuoteList, &q_level, &force_redraw,
while (display_line (fp, &last_pos, &lineInfo, i, &lastLine,
&maxLine, has_types,
&QuoteList, &q_level, &force_redraw,
+ redraw |= REDRAW_SIDEBAR;
+ }
topline = upNLines (bodylen, lineInfo, lastLine, hideQuoted);
}
else
topline = upNLines (bodylen, lineInfo, lastLine, hideQuoted);
}
else
&QuoteList, &q_level, &force_redraw,
&SearchRE) == 0)
{
&QuoteList, &q_level, &force_redraw,
&SearchRE) == 0)
{
+ redraw |= REDRAW_SIDEBAR;
if (! lineInfo[topline].continuation)
j--;
if (j > 0)
if (! lineInfo[topline].continuation)
j--;
if (j > 0)