equal
deleted
inserted
replaced
571 of the chosen chunks. |
571 of the chosen chunks. |
572 """ |
572 """ |
573 ui.write(_(b'starting interactive selection\n')) |
573 ui.write(_(b'starting interactive selection\n')) |
574 chunkselector = curseschunkselector(headerlist, ui, operation) |
574 chunkselector = curseschunkselector(headerlist, ui, operation) |
575 origsigtstp = sentinel = object() |
575 origsigtstp = sentinel = object() |
576 if util.safehasattr(signal, 'SIGTSTP'): |
576 if hasattr(signal, 'SIGTSTP'): |
577 origsigtstp = signal.getsignal(signal.SIGTSTP) |
577 origsigtstp = signal.getsignal(signal.SIGTSTP) |
578 try: |
578 try: |
579 with util.with_lc_ctype(): |
579 with util.with_lc_ctype(): |
580 curses.wrapper(chunkselector.main) |
580 curses.wrapper(chunkselector.main) |
581 if chunkselector.initexc is not None: |
581 if chunkselector.initexc is not None: |
1942 """ |
1942 """ |
1943 method to be wrapped by curses.wrapper() for selecting chunks. |
1943 method to be wrapped by curses.wrapper() for selecting chunks. |
1944 """ |
1944 """ |
1945 |
1945 |
1946 origsigwinch = sentinel = object() |
1946 origsigwinch = sentinel = object() |
1947 if util.safehasattr(signal, 'SIGWINCH'): |
1947 if hasattr(signal, 'SIGWINCH'): |
1948 origsigwinch = signal.signal(signal.SIGWINCH, self.sigwinchhandler) |
1948 origsigwinch = signal.signal(signal.SIGWINCH, self.sigwinchhandler) |
1949 try: |
1949 try: |
1950 return self._main(stdscr) |
1950 return self._main(stdscr) |
1951 finally: |
1951 finally: |
1952 if origsigwinch is not sentinel: |
1952 if origsigwinch is not sentinel: |