changeset 8220:6e6ebeb52899

ui: ui.copy() now takes the ui class into account Helps subclassing by other API users.
author Ronny Pfannschmidt <Ronny.Pfannschmidt@gmx.de>
date Mon, 27 Apr 2009 10:33:57 +0200
parents 21cf74ff2deb
children f35b933044cc
files mercurial/ui.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/ui.py	Mon Apr 27 09:12:07 2009 +0200
+++ b/mercurial/ui.py	Mon Apr 27 10:33:57 2009 +0200
@@ -35,7 +35,7 @@
             for f in util.rcpath():
                 self.readconfig(f, trust=True)
     def copy(self):
-        return ui(self)
+        return self.__class__(self)
 
     def _is_trusted(self, fp, f):
         st = util.fstat(fp)