Closed by commit rHGcd4f1b7c3192: crecord: make KEY_ENTER usable in tests (by not updating UI) (authored by spectral). This revision was automatically updated to reflect the committed changes.
REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D6620?vs=15812&id=15821 CHANGES SINCE LAST ACTION https://phab.mercurial-scm.org/D6620/new/ REVISION DETAIL https://phab.mercurial-scm.org/D6620 AFFECTED FILES mercurial/crecord.py CHANGE DETAILS diff --git a/mercurial/crecord.py b/mercurial/crecord.py --- a/mercurial/crecord.py +++ b/mercurial/crecord.py @@ -723,7 +723,7 @@ self.currentselecteditem = nextitem self.recenterdisplayedarea() - def nextsametype(self): + def nextsametype(self, test=False): currentitem = self.currentselecteditem sametype = lambda item: isinstance(item, type(currentitem)) nextitem = currentitem.nextitem() @@ -739,7 +739,8 @@ self.togglefolded(parent) self.currentselecteditem = nextitem - self.recenterdisplayedarea() + if not test: + self.recenterdisplayedarea() def rightarrowevent(self): """ @@ -1753,7 +1754,7 @@ self.toggleapply() elif keypressed in ['\n', 'KEY_ENTER']: self.toggleapply() - self.nextsametype() + self.nextsametype(test=test) elif keypressed in ['A']: self.toggleall() elif keypressed in ['e']: To: spectral, #hg-reviewers, pulkit Cc: mercurial-devel _______________________________________________ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel