lkundrak / rpms / vim

Forked from rpms/vim 4 years ago
Clone
dd82635
To: vim-dev@vim.org
dd82635
Subject: Patch 7.2.277
dd82635
Fcc: outbox
dd82635
From: Bram Moolenaar <Bram@moolenaar.net>
dd82635
Mime-Version: 1.0
dd82635
Content-Type: text/plain; charset=UTF-8
dd82635
Content-Transfer-Encoding: 8bit
dd82635
------------
dd82635
dd82635
Patch 7.2.277
dd82635
Problem:    CTRL-Y in a diff'ed window may move the cursor outside of the
dd82635
	    window. (Lech Lorens)
dd82635
Solution:   Limit the number of filler lines to the height of the window.
dd82635
	    Don't reset filler lines to zero for an empty buffer.
dd82635
Files:	    src/move.c
dd82635
dd82635
dd82635
*** ../vim-7.2.276/src/move.c	2009-05-15 21:31:11.000000000 +0200
dd82635
--- src/move.c	2009-11-03 14:39:55.000000000 +0100
dd82635
***************
dd82635
*** 183,191 ****
dd82635
  	if (curwin->w_topline != 1)
dd82635
  	    redraw_later(NOT_VALID);
dd82635
  	curwin->w_topline = 1;
dd82635
- #ifdef FEAT_DIFF
dd82635
- 	curwin->w_topfill = 0;
dd82635
- #endif
dd82635
  	curwin->w_botline = 2;
dd82635
  	curwin->w_valid |= VALID_BOTLINE|VALID_BOTLINE_AP;
dd82635
  #ifdef FEAT_SCROLLBIND
dd82635
--- 183,188 ----
dd82635
***************
dd82635
*** 1257,1263 ****
dd82635
      while (line_count-- > 0)
dd82635
      {
dd82635
  #ifdef FEAT_DIFF
dd82635
! 	if (curwin->w_topfill < diff_check(curwin, curwin->w_topline))
dd82635
  	{
dd82635
  	    ++curwin->w_topfill;
dd82635
  	    ++done;
dd82635
--- 1254,1261 ----
dd82635
      while (line_count-- > 0)
dd82635
      {
dd82635
  #ifdef FEAT_DIFF
dd82635
! 	if (curwin->w_topfill < diff_check(curwin, curwin->w_topline)
dd82635
! 		&& curwin->w_topfill < curwin->w_height - 1)
dd82635
  	{
dd82635
  	    ++curwin->w_topfill;
dd82635
  	    ++done;
dd82635
*** ../vim-7.2.276/src/version.c	2009-11-03 16:03:59.000000000 +0100
dd82635
--- src/version.c	2009-11-03 16:22:04.000000000 +0100
dd82635
***************
dd82635
*** 678,679 ****
dd82635
--- 678,681 ----
dd82635
  {   /* Add new patch number below this line */
dd82635
+ /**/
dd82635
+     277,
dd82635
  /**/
dd82635
dd82635
-- 
dd82635
SIGFUN -- signature too funny (core dumped)
dd82635
dd82635
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
dd82635
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
dd82635
\\\        download, build and distribute -- http://www.A-A-P.org        ///
dd82635
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///