Rev 1846 | Rev 3017 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 1846 | Rev 2585 | ||
---|---|---|---|
Line 71... | Line 71... | ||
71 | return 'n' |
71 | return 'n' |
72 | 72 | ||
73 | def _print_choice(self, text, choices, defopt): |
73 | def _print_choice(self, text, choices, defopt): |
74 | sys.stdout.write('%s:\n' % text) |
74 | sys.stdout.write('%s:\n' % text) |
75 | for i,(text,descr) in enumerate(choices): |
75 | for i,(text,descr) in enumerate(choices): |
- | 76 | if descr is '': |
|
- | 77 | sys.stdout.write('\t%2d. %s\n' % (i, text)) |
|
- | 78 | else: |
|
76 | sys.stdout.write('\t%2d. %s\n' % (i, descr)) |
79 | sys.stdout.write('\t%2d. %s\n' % (i, descr)) |
77 | if defopt is not None: |
80 | if defopt is not None: |
78 | sys.stdout.write('Enter choice number[%d]: ' % defopt) |
81 | sys.stdout.write('Enter choice number[%d]: ' % defopt) |
79 | else: |
82 | else: |
80 | sys.stdout.write('Enter choice number: ') |
83 | sys.stdout.write('Enter choice number: ') |
81 | 84 |