diff console/libgnt/gntbindable.c @ 15777:c2c2a854f5b3

Change a bit how the keystrokes are processed. When a lot of keystrokes come in at the same time, the shortest key-combination is processed first. This should make typing fast over a very slow connection work properly.
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Wed, 07 Mar 2007 12:58:34 +0000
parents 7a52dce840b4
children 1c8f1dc50685
line wrap: on
line diff
--- a/console/libgnt/gntbindable.c	Tue Mar 06 07:17:27 2007 +0000
+++ b/console/libgnt/gntbindable.c	Wed Mar 07 12:58:34 2007 +0000
@@ -155,6 +155,7 @@
 
 	if (name == NULL || *name == '\0') {
 		g_hash_table_remove(klass->bindings, (char*)trigger);
+		gnt_keys_del_combination(trigger);
 		return;
 	}
 
@@ -171,6 +172,7 @@
 	param->action = action;
 	param->list = list;
 	g_hash_table_replace(klass->bindings, g_strdup(trigger), param);
+	gnt_keys_add_combination(trigger);
 }
 
 void gnt_bindable_register_binding(GntBindableClass *klass, const char *name,