From 31b6f1d5a76c9a37da074011866fc6d68b0413d6 Mon Sep 17 00:00:00 2001 From: mitchell <70453897+667e-11@users.noreply.github.com> Date: Thu, 5 Feb 2009 17:00:55 -0500 Subject: Don't hide the find box on ESC if the command entry has focus; src/textadept.c --- src/textadept.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/textadept.c b/src/textadept.c index cd823e86..62053c11 100644 --- a/src/textadept.c +++ b/src/textadept.c @@ -506,7 +506,8 @@ static gbool w_focus(GtkWidget*, GdkEventFocus*, gpointer) { * - Escape - hides the search frame if it's open. */ static gbool w_keypress(GtkWidget*, GdkEventKey *event, gpointer) { - if (event->keyval == 0xff1b && GTK_WIDGET_VISIBLE(findbox)) { + if (event->keyval == 0xff1b && GTK_WIDGET_VISIBLE(findbox) && + !GTK_WIDGET_HAS_FOCUS(command_entry)) { gtk_widget_hide(findbox); gtk_widget_grab_focus(focused_editor); return TRUE; -- cgit v1.2.3