Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 0.8, 0.8.1, and 0.8.2

hglib/hgtk/serve: remove use of ui.parentui

adapt to changes in mercurial.ui d2899a856f9f4cc0ee161d5b266fe10401face42

Changeset 435f7adc9c6b

Parent 0be45d66bf92

by Simon Heimberg

Changes to 3 files · Browse files at 435f7adc9c6b Showing diff from parent 0be45d66bf92 Diff from another changeset...

Change 1 of 1 Show Entire File hggtk/​hglib.py Stacked
 
109
110
111
112
113
114
115
116
117
118
119
120
 
 
 
 
 
 
121
122
123
 
109
110
111
 
 
 
 
 
 
 
 
 
112
113
114
115
116
117
118
119
120
@@ -109,15 +109,12 @@
  main thread to pickup.   '''   def __init__(self, outputq=None, dialogq=None, responseq=None, - parentui=None): - super(GtkUi, self).__init__() - if parentui: - self.parentui = parentui.parentui or parentui - self.cdata = ui.dupconfig(self.parentui.cdata) - self.verbose = parentui.verbose - self.outputq = parentui.outputq - self.dialogq = parentui.dialogq - self.responseq = parentui.responseq + src=None): + super(GtkUi, self).__init__(src) + if src: + self.outputq = src.outputq + self.dialogq = src.dialogq + self.responseq = src.responseq   else:   self.outputq = outputq   self.dialogq = dialogq
Change 1 of 1 Show Entire File hggtk/​hgtk.py Stacked
 
144
145
146
147
 
148
149
150
 
144
145
146
 
147
148
149
150
@@ -144,7 +144,7 @@
  path = hglib.rootpath(os.getcwd())   if path:   try: - lui = _ui.ui(parentui=ui) + lui = hasattr(_ui, 'copy') and _ui.copy() or _ui.ui(ui)   lui.readconfig(os.path.join(path, ".hg", "hgrc"))   except IOError:   pass
Change 1 of 1 Show Entire File hggtk/​serve.py Stacked
 
278
279
280
281
 
 
 
282
283
284
285
286
287
288
 
 
 
289
290
291
 
278
279
280
 
281
282
283
284
285
286
287
 
 
 
288
289
290
291
292
293
@@ -278,14 +278,16 @@
  self.stopped = True   util.set_signal_handler()   try: - parentui = ui.parentui or ui + baseui = (getattr(repo, 'baseui', None) or + getattr(ui, 'parentui', None) or ui) + repoui = repo and repo.ui != baseui and repo.ui or None   optlist = ("name templates style address port prefix ipv6"   " accesslog errorlog webdir_conf certificate")   for o in optlist.split():   if opts[o]: - parentui.setconfig("web", o, str(opts[o])) - if (repo is not None) and (repo.ui != parentui): - repo.ui.setconfig("web", o, str(opts[o])) + baseui.setconfig("web", o, str(opts[o])) + if repoui: + repoui.setconfig("web", o, str(opts[o]))   self.httpd = server.create_server(ui, repo)   except socket.error, inst:   raise util.Abort(_('cannot start server: ') + inst.args[1])