/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 diff.py

  • Committer: Aaron Bentley
  • Date: 2008-05-12 20:21:45 UTC
  • mto: This revision was merged to the branch mainline in revision 492.
  • Revision ID: aaron@aaronbentley.com-20080512202145-7dh7wm8avi3ud47q
Update error handling to use window

Show diffs side-by-side

added added

removed removed

Lines of Context:
479
479
                       _('Please resolve the conflicts manually'
480
480
                         ' before committing.'))
481
481
 
 
482
    def _handle_error(self, e):
 
483
        error_dialog('Error', str(e))
482
484
 
483
485
    def _get_save_path(self, basename):
484
486
        d = gtk.FileChooserDialog('Save As', self,
550
552
 
551
553
class MergeDirectiveController(DiffController):
552
554
 
553
 
    def __init__(self, path, directive, window):
 
555
    def __init__(self, path, directive, window=None):
554
556
        DiffController.__init__(self, path, directive.patch.splitlines(True),
555
557
                                window)
556
558
        self.directive = directive
582
584
                    # There are conflicts to be resolved.
583
585
                self.window.destroy()
584
586
            except Exception, e:
585
 
                error_dialog('Error', str(e))
 
587
                self.window._handle_error(e)
586
588
        finally:
587
589
            tree.unlock()
588
590