diff finch/gntblist.c @ 21305:0208beabfa33

Cancel the typeahead search when escape is pressed.
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Sun, 11 Nov 2007 19:42:02 +0000
parents a20ef7180680
children 665e04562de0
line wrap: on
line diff
--- a/finch/gntblist.c	Sat Nov 10 23:48:57 2007 +0000
+++ b/finch/gntblist.c	Sun Nov 11 19:42:02 2007 +0000
@@ -1506,6 +1506,8 @@
 {
 	if (text[0] == 27 && text[1] == 0) {
 		/* Escape was pressed */
+		if (gnt_tree_is_searching(GNT_TREE(ggblist->tree)))
+			gnt_bindable_perform_action_named(GNT_BINDABLE(ggblist->tree), "end-search", NULL);
 		remove_peripherals(ggblist);
 	} else if (strcmp(text, GNT_KEY_CTRL_O) == 0) {
 		purple_prefs_set_bool(PREF_ROOT "/showoffline",