[kupfer] Allow binding Escape or BackSpace with modifiers



commit 5c39c07fc01a2958c5dd4ecc183aac98664756d7
Author: Ulrik Sverdrup <ulrik sverdrup gmail com>
Date:   Tue Apr 6 21:45:21 2010 +0200

    Allow binding Escape or BackSpace with modifiers

 kupfer/ui/getkey_dialog.py |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/kupfer/ui/getkey_dialog.py b/kupfer/ui/getkey_dialog.py
index 12b2e4e..014dc10 100644
--- a/kupfer/ui/getkey_dialog.py
+++ b/kupfer/ui/getkey_dialog.py
@@ -69,7 +69,7 @@ class GetKeyDialogController(object):
 		self._press_time = event.time
 
 		keyval, state = self.translate_keyboard_event(event)
-		keyname = gtk.gdk.keyval_name(keyval)
+		keyname = gtk.accelerator_name(keyval, state)
 		if keyname == 'Escape':
 			self._return(None)
 		elif keyname == 'BackSpace':



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]