commit 66986591490404d12c289ad7a2198110a5faa923
parent 06b449b22c85cce628875cf80fbaa3ae21eb8259
Author: Benno Schulenberg <bensberg@justemail.net>
Date: Sat, 14 May 2016 21:49:19 +0200
screen: displaying the cursor position should not suppress it next time
Take the side effect of a 'statusbar' call -- setting suppress_cursorpos
to TRUE -- into account. This effect was overlooked by commit 9d6d5b6.
Diffstat:
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/src/winio.c b/src/winio.c
@@ -3059,10 +3059,9 @@ void do_cursorpos(bool constant)
openfile->current->next = f;
/* If the position needs to be suppressed, don't suppress it next time. */
- if (suppress_cursorpos) {
+ if (suppress_cursorpos && constant) {
suppress_cursorpos = FALSE;
- if (constant)
- return;
+ return;
}
/* Display the current cursor position on the statusbar. */
@@ -3076,6 +3075,9 @@ void do_cursorpos(bool constant)
(long)openfile->filebot->lineno, linepct,
(unsigned long)cur_xpt, (unsigned long)cur_lenpt, colpct,
(unsigned long)i, (unsigned long)openfile->totsize, charpct);
+
+ /* Displaying the cursor position should not suppress it next time. */
+ suppress_cursorpos = FALSE;
}
/* Unconditionally display the current cursor position. */