~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/progress.py

  • Committer: Martin Pool
  • Date: 2008-12-16 06:59:58 UTC
  • mto: (3882.7.11 progress)
  • mto: This revision was merged to the branch mainline in revision 3940.
  • Revision ID: mbp@sourcefrog.net-20081216065958-b4ce9x9w34xwan5a
Progress and UI test cleanups

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright (C) 2005 Aaron Bentley <aaron.bentley@utoronto.ca>
2
1
# Copyright (C) 2005, 2006, 2008 Canonical Ltd
3
2
#
4
3
# This program is free software; you can redistribute it and/or modify
91
90
            self.total_cnt = total_cnt
92
91
        self.ui_factory.show_progress(self)
93
92
 
 
93
    def tick(self):
 
94
        self.update(self.msg)
 
95
 
94
96
    def finished(self):
95
97
        self.ui_factory.progress_finished(self)
96
98
 
145
147
        return _progress_bar_types[requested_bar_type](to_file=to_file, **kwargs)
146
148
 
147
149
 
148
 
 
149
150
class TextProgressView(object):
150
151
    """Display of progress bar and other information on a tty.
151
152
    
393
394
 
394
395
    This can be used as the default argument for methods that
395
396
    take an optional progress indicator."""
 
397
 
396
398
    def tick(self):
397
399
        pass
398
400