Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 1.0, 1.0.1, and 1.0.2

gdialog: prevent traceback from unusual standard dialog layout

Closes #792

Changeset f6009be3d5ad

Parent 0d30a9d62bbb

by Steve Borho

Changes to one file · Browse files at f6009be3d5ad Showing diff from parent 0d30a9d62bbb Diff from another changeset...

 
40
41
42
43
44
45
 
 
 
 
 
 
46
47
48
 
40
41
42
 
 
 
43
44
45
46
47
48
49
50
51
@@ -40,9 +40,12 @@
  key, modifier = gtk.accelerator_parse(mod+'Return')   accel_group = gtk.AccelGroup()   self.add_accel_group(accel_group) - buttons = self.get_children()[0].get_children()[1].get_children() - buttons[0].add_accelerator('clicked', accel_group, key, - modifier, gtk.ACCEL_VISIBLE) + try: + buttons = self.get_children()[0].get_children()[1].get_children() + buttons[0].add_accelerator('clicked', accel_group, key, + modifier, gtk.ACCEL_VISIBLE) + except IndexError: + pass    class CustomPrompt(gtk.MessageDialog):   ''' Custom prompt dialog. Provide a list of choices with ampersands