prevent traceback when no callback is given in ConfirmationDialogCheck dialog
This commit is contained in:
		
							parent
							
								
									b22da6ead9
								
							
						
					
					
						commit
						436adf7b95
					
				
					 1 changed files with 4 additions and 2 deletions
				
			
		|  | @ -1089,10 +1089,12 @@ class ConfirmationDialogCheck(ConfirmationDialog): | ||||||
| 	# XXX should cancel if somebody closes the dialog | 	# XXX should cancel if somebody closes the dialog | ||||||
| 
 | 
 | ||||||
| 	def on_response_ok(self, widget): | 	def on_response_ok(self, widget): | ||||||
|  | 		if self.user_response_ok: | ||||||
| 			self.user_response_ok(self.is_checked()) | 			self.user_response_ok(self.is_checked()) | ||||||
| 		self.destroy() | 		self.destroy() | ||||||
| 
 | 
 | ||||||
| 	def on_response_cancel(self, widget): | 	def on_response_cancel(self, widget): | ||||||
|  | 		if self.user_response_cancel: | ||||||
| 			self.user_response_cancel() | 			self.user_response_cancel() | ||||||
| 		self.destroy() | 		self.destroy() | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		
		Reference in a new issue