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

  • Committer: Jelmer Vernooij
  • Date: 2007-10-26 17:02:18 UTC
  • Revision ID: jelmer@samba.org-20071026170218-pepec3wazqr3ghhb
Add very simple "Send Merge Directive" window.

Show diffs side-by-side

added added

removed removed

Lines of Context:
389
389
    """
390
390
    def run(self):
391
391
        (br, path) = branch.Branch.open_containing(".")
 
392
        gtk = self.open_display()
392
393
        from bzrlib.plugins.gtk.mergedirective import SendMergeDirectiveDialog
 
394
        from StringIO import StringIO
393
395
        dialog = SendMergeDirectiveDialog(br)
394
 
        dialog.run()
 
396
        if dialog.run() == gtk.RESPONSE_OK:
 
397
            outf = StringIO()
 
398
            outf.writelines(dialog.get_merge_directive().to_lines())
 
399
            mail_client = br.get_config().get_mail_client()
 
400
            mail_client.compose_merge_request(dialog.get_mail_to(), "[MERGE]", 
 
401
                outf.getvalue())
 
402
 
 
403
            
395
404
 
396
405
 
397
406
class cmd_gconflicts(GTKCommand):