aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/message.c
diff options
context:
space:
mode:
authorBjörn Linse <bjorn.linse@gmail.com>2019-02-07 21:41:45 +0100
committerGitHub <noreply@github.com>2019-02-07 21:41:45 +0100
commitf6faeea41c70015f6d9b63fecaf80d106cd2636d (patch)
tree00be473f5509a9cc085a64ab29b0fadb9f9412b3 /src/nvim/message.c
parentfa2580f953204e919a13388ce5af2edf3afd0594 (diff)
parentbe8058cfe4b7adff60a68d9503a01e322d7d2ff9 (diff)
downloadrneovim-f6faeea41c70015f6d9b63fecaf80d106cd2636d.tar.gz
rneovim-f6faeea41c70015f6d9b63fecaf80d106cd2636d.tar.bz2
rneovim-f6faeea41c70015f6d9b63fecaf80d106cd2636d.zip
Merge pull request #9586 from bfredl/screencleanup
screen: cleanup allocation and scrolling
Diffstat (limited to 'src/nvim/message.c')
-rw-r--r--src/nvim/message.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/nvim/message.c b/src/nvim/message.c
index 4552999256..971a14974c 100644
--- a/src/nvim/message.c
+++ b/src/nvim/message.c
@@ -946,9 +946,9 @@ void wait_return(int redraw)
c = CAR; /* no need for a return in ex mode */
got_int = FALSE;
} else {
- /* Make sure the hit-return prompt is on screen when 'guioptions' was
- * just changed. */
- screenalloc(false);
+ // Make sure the hit-return prompt is on screen when 'guioptions' was
+ // just changed.
+ screenalloc();
State = HITRETURN;
setmouse();
@@ -2392,9 +2392,8 @@ static int do_more_prompt(int typed_char)
mp_last = msg_sb_start(mp_last->sb_prev);
}
- if (toscroll == -1
- && grid_ins_lines(&default_grid, 0, 1, (int)Rows,
- 0, (int)Columns) == OK) {
+ if (toscroll == -1) {
+ grid_ins_lines(&default_grid, 0, 1, (int)Rows, 0, (int)Columns);
grid_fill(&default_grid, 0, 1, 0, (int)Columns, ' ', ' ', 0);
// display line at top
(void)disp_sb_line(0, mp);