changeset 18000:05d7fe2320a9

(16:39:44) rekkanoryo: i have a feature request (16:39:55) rekkanoryo: make shift+tab go backwards through the widgets
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Sat, 02 Jun 2007 20:56:12 +0000
parents fc2bb1b42868
children 55a90b3fb1a1
files finch/libgnt/gntbox.c finch/libgnt/gntkeys.c finch/libgnt/gntkeys.h
diffstat 3 files changed, 6 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/finch/libgnt/gntbox.c	Sat Jun 02 18:47:20 2007 +0000
+++ b/finch/libgnt/gntbox.c	Sat Jun 02 20:56:12 2007 +0000
@@ -293,6 +293,10 @@
 		{
 			find_next_focus(box);
 		}
+		else if (strcmp(text, GNT_KEY_BACK_TAB) == 0)
+		{
+			find_prev_focus(box);
+		}
 	}
 	else if (text[0] == '\t')
 	{
--- a/finch/libgnt/gntkeys.c	Sat Jun 02 18:47:20 2007 +0000
+++ b/finch/libgnt/gntkeys.c	Sat Jun 02 20:56:12 2007 +0000
@@ -50,6 +50,7 @@
 	INSERT_KEY("pagedown", GNT_KEY_PGDOWN);
 	INSERT_KEY("insert",   GNT_KEY_INS);
 	INSERT_KEY("delete",   GNT_KEY_DEL);
+	INSERT_KEY("back_tab", GNT_KEY_BACK_TAB);
 
 	INSERT_KEY("left",   GNT_KEY_LEFT);
 	INSERT_KEY("right",  GNT_KEY_RIGHT);
--- a/finch/libgnt/gntkeys.h	Sat Jun 02 18:47:20 2007 +0000
+++ b/finch/libgnt/gntkeys.h	Sat Jun 02 20:56:12 2007 +0000
@@ -39,6 +39,7 @@
 #define GNT_KEY_BACKSPACE SAFE(key_backspace)
 #define GNT_KEY_DEL    SAFE(key_dc)
 #define GNT_KEY_INS    SAFE(key_ic)
+#define GNT_KEY_BACK_TAB SAFE(back_tab)
 
 #define GNT_KEY_CTRL_A     "\001"
 #define GNT_KEY_CTRL_B     "\002"