diff options
author | Bram Moolenaar <Bram@vim.org> | 2017-09-16 20:54:51 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2017-09-16 20:54:51 +0200 |
commit | 4033c55eca575777718c0701e26635a0cc47d907 (patch) | |
tree | 8dc460ad495106198a9119b52f6505033f7a75b3 /src/move.c | |
parent | e738a1a033cd31cd2568ba99a9e2dca1e65b45ea (diff) | |
download | vim-git-4033c55eca575777718c0701e26635a0cc47d907.tar.gz |
patch 8.0.1118: FEAT_WINDOWS adds a lot of #ifdefsv8.0.1118
Problem: FEAT_WINDOWS adds a lot of #ifdefs while it is nearly always
enabled and only adds 7% to the binary size of the tiny build.
Solution: Graduate FEAT_WINDOWS.
Diffstat (limited to 'src/move.c')
-rw-r--r-- | src/move.c | 31 |
1 files changed, 5 insertions, 26 deletions
diff --git a/src/move.c b/src/move.c index a5ba011ef..c520f5fd5 100644 --- a/src/move.c +++ b/src/move.c @@ -982,11 +982,7 @@ curs_columns( curwin->w_wcol = W_WIDTH(curwin) - 1; curwin->w_wrow = curwin->w_height - 1; } - else if (curwin->w_p_wrap -#ifdef FEAT_WINDOWS - && curwin->w_width != 0 -#endif - ) + else if (curwin->w_p_wrap && curwin->w_width != 0) { width = textwidth + curwin_col_off2(); @@ -1089,10 +1085,7 @@ curs_columns( && curwin->w_height != 0 && curwin->w_cursor.lnum == curwin->w_topline && width > 0 -#ifdef FEAT_WINDOWS - && curwin->w_width != 0 -#endif - ) + && curwin->w_width != 0) { /* Cursor past end of screen. Happens with a single line that does * not fit on screen. Find a skipcol to show the text around the @@ -1251,11 +1244,7 @@ scrolldown( * and move the cursor onto the displayed part of the window. */ wrow = curwin->w_wrow; - if (curwin->w_p_wrap -#ifdef FEAT_WINDOWS - && curwin->w_width != 0 -#endif - ) + if (curwin->w_p_wrap && curwin->w_width != 0) { validate_virtcol(); validate_cheight(); @@ -1460,11 +1449,7 @@ scrolldown_clamp(void) #else end_row += plines(curwin->w_topline - 1); #endif - if (curwin->w_p_wrap -#ifdef FEAT_WINDOWS - && curwin->w_width != 0 -#endif - ) + if (curwin->w_p_wrap && curwin->w_width != 0) { validate_cheight(); validate_virtcol(); @@ -1524,11 +1509,7 @@ scrollup_clamp(void) #else start_row = curwin->w_wrow - plines(curwin->w_topline); #endif - if (curwin->w_p_wrap -#ifdef FEAT_WINDOWS - && curwin->w_width != 0 -#endif - ) + if (curwin->w_p_wrap && curwin->w_width != 0) { validate_virtcol(); start_row -= curwin->w_virtcol / W_WIDTH(curwin); @@ -2855,9 +2836,7 @@ do_check_cursorbind(void) /* Only scroll when 'scrollbind' hasn't done this. */ if (!curwin->w_p_scb) update_topline(); -# ifdef FEAT_WINDOWS curwin->w_redr_status = TRUE; -# endif } } |