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

hggtk/*: ui.interactive is not bool anymore

adapt to changes in mercurial.ui (32a2a1e244f183298c1195c90c65a7a1d23dcee6)

Changeset 278134c79beb

Parent 435f7adc9c6b

by Simon Heimberg

Changes to 4 files · Browse files at 278134c79beb Showing diff from parent 435f7adc9c6b Diff from another changeset...

Change 1 of 1 Show Entire File hggtk/​gdialog.py Stacked
 
92
93
94
95
 
96
97
98
 
92
93
94
 
95
96
97
98
@@ -92,7 +92,7 @@
  gtk.Window.__init__(self, gtk.WINDOW_TOPLEVEL)   self.cwd = cwd or os.getcwd()   self.ui = ui - self.ui.interactive=False + self.ui.setconfig('ui', 'interactive', 'off')   self.repo = repo or hg.repository(ui, path=hglib.rootpath())   self.pats = pats   self.opts = opts
Change 1 of 2 Show Entire File hggtk/​hglib.py Stacked
 
101
102
103
 
 
 
104
105
106
 
137
138
139
140
 
141
142
143
 
101
102
103
104
105
106
107
108
109
 
140
141
142
 
143
144
145
146
@@ -101,6 +101,9 @@
  return line[0] + line[1:].expandtabs(_tabwidth)     +def calliffunc(f): + return hasattr(f, '__call__') and f() or f +  class GtkUi(ui.ui):   '''   PyGtk enabled mercurial.ui subclass. All this code will be running @@ -137,7 +140,7 @@
    def prompt(self, msg, pat=None, default="y"):   import re - if not self.interactive: return default + if not calliffunc(self.interactive): return default   while True:   try:   # send request to main thread, await response
Change 1 of 1 Show Entire File hggtk/​hgshelve.py Stacked
 
420
421
422
423
 
424
425
426
 
420
421
422
 
423
424
425
426
@@ -420,7 +420,7 @@
    ? - display help'''   - if not ui.interactive: + if not hglib.calliffunc(ui.interactive):   raise util.Abort(_('shelve can only be run interactively'))     forced = opts['force'] or opts['append']
 
176
177
178
179
 
180
181
182
 
176
177
178
 
179
180
181
182
@@ -176,7 +176,7 @@
  return sc     # shelve them! - self.ui.interactive = True # hgshelve only works 'interactively' + self.ui.setconfig('ui', 'interactive', 'on') # hgshelve only works 'interactively'   opts = {'addremove': None, 'include': [], 'force': doforce,   'append': doappend, 'exclude': []}   hgshelve.filterpatch = filter_patch