Example #1
0
    def pull_cb(self, menu, vfs_file):
        # We can only cope with local files
        if vfs_file.get_uri_scheme() != 'file':
            return

        file = vfs_file.get_uri()

        # We only want to continue here if we get a NotBranchError
        try:
            tree, path = WorkingTree.open_containing(file)
        except NotBranchError:
            return

        from bzrlib.plugins.gtk.pull import PullDialog
        dialog = PullDialog(tree, path)
        dialog.display()
        gtk.main()
Example #2
0
 def pull_cb(self, menu, controldir, path=None):
     from bzrlib.plugins.gtk.pull import PullDialog
     dialog = PullDialog(controldir.open_workingtree(), path)
     dialog.display()
     Gtk.main()