Show More
@@ -1246,7 +1246,7 b' class ui(object):' | |||
|
1246 | 1246 | |
|
1247 | 1247 | return i |
|
1248 | 1248 | |
|
1249 |
def _readline(self |
|
|
1249 | def _readline(self): | |
|
1250 | 1250 | if self._isatty(self.fin): |
|
1251 | 1251 | try: |
|
1252 | 1252 | # magically add command line editing support, where |
@@ -1258,11 +1258,6 b' class ui(object):' | |||
|
1258 | 1258 | except Exception: |
|
1259 | 1259 | pass |
|
1260 | 1260 | |
|
1261 | # call write() so output goes through subclassed implementation | |
|
1262 | # e.g. color extension on Windows | |
|
1263 | self.write(prompt, prompt=True) | |
|
1264 | self.flush() | |
|
1265 | ||
|
1266 | 1261 | # prompt ' ' must exist; otherwise readline may delete entire line |
|
1267 | 1262 | # - http://bugs.python.org/issue12833 |
|
1268 | 1263 | with self.timeblockedsection('stdio'): |
@@ -1281,8 +1276,10 b' class ui(object):' | |||
|
1281 | 1276 | if not self.interactive(): |
|
1282 | 1277 | self.write(msg, ' ', default or '', "\n") |
|
1283 | 1278 | return default |
|
1279 | self.write(msg, label='ui.prompt', prompt=True) | |
|
1280 | self.flush() | |
|
1284 | 1281 | try: |
|
1285 |
r = self._readline( |
|
|
1282 | r = self._readline() | |
|
1286 | 1283 | if not r: |
|
1287 | 1284 | r = default |
|
1288 | 1285 | if self.configbool('ui', 'promptecho'): |
General Comments 0
You need to be logged in to leave comments.
Login now