Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 0.8, 0.8.1, and 0.8.2

thgconfig: only emit_stop_by_name() when applicable

If the user hits ctrl-w or ctrl-q, should_live() will get zero
arguments and there is no signal to stop. This prevents a GTK+
warning if the keyboard accelerator triggered the close.

Changeset 1ce1f29483cd

Parent c6442e9f9006

by Steve Borho

Changes to one file · Browse files at 1ce1f29483cd Showing diff from parent c6442e9f9006 Diff from another changeset...

 
540
541
542
543
544
 
 
 
545
546
547
 
540
541
542
 
 
543
544
545
546
547
548
@@ -540,8 +540,9 @@
  ret = gdialog.Confirm(_('Confirm quit without saving?'), [], self,   _('Yes to abandon changes, No to continue')).run()   if ret != gtk.RESPONSE_YES: - self.emit_stop_by_name('response') - return True + if len(args) != 0: + self.emit_stop_by_name('response') + return True   return False     def focus_field(self, focusfield):