mercurial/crecord.py
changeset 30554 f3cff00c7a00
parent 30553 d4035372db8d
child 30555 9b674957e2e4
--- a/mercurial/crecord.py	Mon Nov 28 23:12:54 2016 +0000
+++ b/mercurial/crecord.py	Wed Nov 23 22:23:15 2016 +0000
@@ -541,7 +541,7 @@
         # keeps track of the number of lines in the pad
         self.numpadlines = None
 
-        self.numstatuslines = 2
+        self.numstatuslines = 1
 
         # keep a running count of the number of lines printed to the pad
         # (used for determining when the selected item begins/ends)
@@ -955,6 +955,9 @@
                        "(space/A) toggle hunk/all; (e)dit hunk;"),
                      _(" (f)old/unfold; (c)onfirm applied; (q)uit; (?) help "
                        "| [X]=hunk applied **=folded, toggle [a]mend mode")]
+        if len(lines) != self.numstatuslines:
+            self.numstatuslines = len(lines)
+            self.statuswin.resize(self.numstatuslines, self.xscreensize)
         return [util.ellipsis(l, self.xscreensize - 1) for l in lines]
 
     def updatescreen(self):
@@ -979,7 +982,7 @@
             self.updatescroll()
             self.chunkpad.refresh(self.firstlineofpadtoprint, 0,
                                   self.numstatuslines, 0,
-                                  self.yscreensize + 1 - self.numstatuslines,
+                                  self.yscreensize - self.numstatuslines,
                                   self.xscreensize)
         except curses.error:
             pass