35
35
def __init__(self, gladefile, comm, dialog):
36
36
""" Initialize the Checkout dialog. """
37
37
self.gladefile = gladefile
38
self.glade = gtk.glade.XML(self.gladefile, 'window_checkout')
38
self.glade = gtk.glade.XML(self.gladefile, 'window_checkout', 'olive-gtk')
40
40
# Communication object
63
63
entry_location = self.glade.get_widget('entry_checkout_location')
64
64
location = entry_location.get_text()
66
self.dialog.error_dialog('Missing branch location',
67
'You must specify a branch location.')
66
self.dialog.error_dialog(_('Missing branch location'),
67
_('You must specify a branch location.'))
70
70
destination = self.filechooser.get_filename()
82
82
init.checkout(location, destination, revno, lightweight)
83
83
except errors.NotBranchError, errmsg:
84
self.dialog.error_dialog('Location is not a branch',
85
'The specified location has to be a branch')
84
self.dialog.error_dialog(_('Location is not a branch'),
85
_('The specified location has to be a branch.'))
86
86
self.comm.set_busy(self.window, False)
88
88
except errors.TargetAlreadyExists, errmsg:
89
self.dialog.error_dialog('Target already exists',
90
'Target directory (%s)\nalready exists. Please select another target.' % errmsg)
89
self.dialog.error_dialog(_('Target already exists'),
90
_('Target directory (%s)\nalready exists. Please select another target.') % errmsg)
91
91
self.comm.set_busy(self.window, False)
93
93
except errors.NonExistingParent, errmsg:
94
self.dialog.error_dialog("Non existing parent directory",
95
"The parent directory (%s)\ndoesn't exist." % errmsg)
94
self.dialog.error_dialog(_('Non existing parent directory'),
95
_("The parent directory (%s)\ndoesn't exist.") % errmsg)
96
96
self.comm.set_busy(self.window, False)