Mercurial > hg-stable
changeset 41991:3f467db023a2
crecord: completely redraw screen when coming back from editor
Differential Revision: https://phab.mercurial-scm.org/D6129
author | Kyle Lippincott <spectral@google.com> |
---|---|
date | Wed, 13 Mar 2019 18:39:36 -0700 |
parents | 22ed63869835 |
children | fa3b0ca9d74f |
files | mercurial/crecord.py |
diffstat | 1 files changed, 11 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/crecord.py Wed Mar 20 20:42:10 2019 +0300 +++ b/mercurial/crecord.py Wed Mar 13 18:39:36 2019 -0700 @@ -554,6 +554,14 @@ of the chosen chunks. """ chunkselector = curseschunkselector(headerlist, ui, operation) + + class dummystdscr(object): + def clear(self): + pass + def refresh(self): + pass + + chunkselector.stdscr = dummystdscr() if testfn and os.path.exists(testfn): testf = open(testfn, 'rb') testcommands = [x.rstrip('\n') for x in testf.readlines()] @@ -1606,6 +1614,9 @@ except error.Abort as exc: self.errorstr = str(exc) return None + finally: + self.stdscr.clear() + self.stdscr.refresh() # remove comment lines patch = [line + '\n' for line in patch.splitlines()