equal
deleted
inserted
replaced
1373 self.printstring(helpwin, line, pairname="legend") |
1373 self.printstring(helpwin, line, pairname="legend") |
1374 except curses.error: |
1374 except curses.error: |
1375 pass |
1375 pass |
1376 helpwin.refresh() |
1376 helpwin.refresh() |
1377 try: |
1377 try: |
1378 helpwin.getkey() |
1378 with self.ui.timeblockedsection('crecord'): |
|
1379 helpwin.getkey() |
1379 except curses.error: |
1380 except curses.error: |
1380 pass |
1381 pass |
1381 |
1382 |
1382 def confirmationwindow(self, windowtext): |
1383 def confirmationwindow(self, windowtext): |
1383 "display an informational window, then wait for and return a keypress." |
1384 "display an informational window, then wait for and return a keypress." |
1390 except curses.error: |
1391 except curses.error: |
1391 pass |
1392 pass |
1392 self.stdscr.refresh() |
1393 self.stdscr.refresh() |
1393 confirmwin.refresh() |
1394 confirmwin.refresh() |
1394 try: |
1395 try: |
1395 response = chr(self.stdscr.getch()) |
1396 with self.ui.timeblockedsection('crecord'): |
|
1397 response = chr(self.stdscr.getch()) |
1396 except ValueError: |
1398 except ValueError: |
1397 response = None |
1399 response = None |
1398 |
1400 |
1399 return response |
1401 return response |
1400 |
1402 |
1410 note: don't add/remove lines unless you also modify the range information. |
1412 note: don't add/remove lines unless you also modify the range information. |
1411 failing to follow this rule will result in the commit aborting. |
1413 failing to follow this rule will result in the commit aborting. |
1412 |
1414 |
1413 are you sure you want to review/edit and confirm the selected changes [yn]? |
1415 are you sure you want to review/edit and confirm the selected changes [yn]? |
1414 """) |
1416 """) |
1415 response = self.confirmationwindow(confirmtext) |
1417 with self.ui.timeblockedsection('crecord'): |
|
1418 response = self.confirmationwindow(confirmtext) |
1416 if response is None: |
1419 if response is None: |
1417 response = "n" |
1420 response = "n" |
1418 if response.lower().startswith("y"): |
1421 if response.lower().startswith("y"): |
1419 return True |
1422 return True |
1420 else: |
1423 else: |
1653 self.currentselecteditem, recursechildren=False) |
1656 self.currentselecteditem, recursechildren=False) |
1654 |
1657 |
1655 while True: |
1658 while True: |
1656 self.updatescreen() |
1659 self.updatescreen() |
1657 try: |
1660 try: |
1658 keypressed = self.statuswin.getkey() |
1661 with self.ui.timeblockedsection('crecord'): |
|
1662 keypressed = self.statuswin.getkey() |
1659 if self.errorstr is not None: |
1663 if self.errorstr is not None: |
1660 self.errorstr = None |
1664 self.errorstr = None |
1661 continue |
1665 continue |
1662 except curses.error: |
1666 except curses.error: |
1663 keypressed = "foobar" |
1667 keypressed = "foobar" |