comparison mercurial/crecord.py @ 48946:642e31cb55f0

py3: use class X: instead of class X(object): The inheritance from object is implied in Python 3. So this should be equivalent. This change was generated via an automated search and replace. So there may have been some accidental changes. Differential Revision: https://phab.mercurial-scm.org/D12352
author Gregory Szorc <gregory.szorc@gmail.com>
date Mon, 21 Feb 2022 13:08:28 -0700
parents 6000f5b25c9b
children 079197e94b24
comparison
equal deleted inserted replaced
48945:55d132525155 48946:642e31cb55f0
80 it) and that the user has the correct flag for the ui. 80 it) and that the user has the correct flag for the ui.
81 """ 81 """
82 return curses and ui.interface(b"chunkselector") == b"curses" 82 return curses and ui.interface(b"chunkselector") == b"curses"
83 83
84 84
85 class patchnode(object): 85 class patchnode:
86 """abstract class for patch graph nodes 86 """abstract class for patch graph nodes
87 (i.e. patchroot, header, hunk, hunkline) 87 (i.e. patchroot, header, hunk, hunkline)
88 """ 88 """
89 89
90 def firstchild(self): 90 def firstchild(self):
599 test interface to get selection of chunks, and mark the applied flags 599 test interface to get selection of chunks, and mark the applied flags
600 of the chosen chunks. 600 of the chosen chunks.
601 """ 601 """
602 chunkselector = curseschunkselector(headerlist, ui, operation) 602 chunkselector = curseschunkselector(headerlist, ui, operation)
603 603
604 class dummystdscr(object): 604 class dummystdscr:
605 def clear(self): 605 def clear(self):
606 pass 606 pass
607 607
608 def refresh(self): 608 def refresh(self):
609 pass 609 pass
626 b'keep': _(b'Select hunks to keep'), 626 b'keep': _(b'Select hunks to keep'),
627 None: _(b'Select hunks to record'), 627 None: _(b'Select hunks to record'),
628 } 628 }
629 629
630 630
631 class curseschunkselector(object): 631 class curseschunkselector:
632 def __init__(self, headerlist, ui, operation=None): 632 def __init__(self, headerlist, ui, operation=None):
633 # put the headers into a patch object 633 # put the headers into a patch object
634 self.headerlist = patch(headerlist) 634 self.headerlist = patch(headerlist)
635 635
636 self.ui = ui 636 self.ui = ui