/b-gtk/fix-viz

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/b-gtk/fix-viz

« back to all changes in this revision

Viewing changes to ui.py

  • Committer: Curtis Hovey
  • Date: 2012-02-27 16:58:13 UTC
  • mto: (776.2.1 ui-factory)
  • mto: This revision was merged to the branch mainline in revision 779.
  • Revision ID: sinzui.is@verizon.net-20120227165813-v5l2g5binwm7e3n2
Added test for main_iteration() and fixed decorator to return the result.

Show diffs side-by-side

added added

removed removed

Lines of Context:
28
28
 
29
29
def main_iteration(function):
30
30
    def with_main_iteration(self, *args, **kwargs):
31
 
        function(self, *args, **kwargs)
 
31
        result = function(self, *args, **kwargs)
32
32
        while Gtk.events_pending():
33
33
            Gtk.main_iteration_do(False)
 
34
        return result
34
35
    return with_main_iteration
35
36
 
36
37