aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/ex_cmds.c
diff options
context:
space:
mode:
authorckelsel <ckelsel@hotmail.com>2017-07-28 08:38:08 +0800
committerckelsel <ckelsel@hotmail.com>2017-07-28 08:38:08 +0800
commit3e0536eb295309c728acca386ec35756b7e034f6 (patch)
treef4ef3ef657245cf6d96a3d777ae63c6fda5b11d0 /src/nvim/ex_cmds.c
parent31c018244daa12caab3af357a368279a1f55d28c (diff)
parente6d54407ba8ce580fbd81cb9389eb9ce4483597b (diff)
downloadrneovim-3e0536eb295309c728acca386ec35756b7e034f6.tar.gz
rneovim-3e0536eb295309c728acca386ec35756b7e034f6.tar.bz2
rneovim-3e0536eb295309c728acca386ec35756b7e034f6.zip
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'src/nvim/ex_cmds.c')
-rw-r--r--src/nvim/ex_cmds.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/nvim/ex_cmds.c b/src/nvim/ex_cmds.c
index 0987cb3915..a555fb77e8 100644
--- a/src/nvim/ex_cmds.c
+++ b/src/nvim/ex_cmds.c
@@ -2802,16 +2802,18 @@ void ex_z(exarg_T *eap)
int j;
linenr_T lnum = eap->line2;
- /* Vi compatible: ":z!" uses display height, without a count uses
- * 'scroll' */
- if (eap->forceit)
+ // Vi compatible: ":z!" uses display height, without a count uses
+ // 'scroll'
+ if (eap->forceit) {
bigness = curwin->w_height;
- else if (firstwin == lastwin)
+ } else if (ONE_WINDOW) {
bigness = curwin->w_p_scr * 2;
- else
+ } else {
bigness = curwin->w_height - 3;
- if (bigness < 1)
+ }
+ if (bigness < 1) {
bigness = 1;
+ }
x = eap->arg;
kind = x;