aboutsummaryrefslogtreecommitdiff
path: root/src/textadept.c
diff options
context:
space:
mode:
authormitchell <70453897+667e-11@users.noreply.github.com>2013-04-24 09:39:27 -0400
committermitchell <70453897+667e-11@users.noreply.github.com>2013-04-24 09:39:27 -0400
commit3164a7e0fb831d910c992d7e4c65d197c4e5305b (patch)
treec6b5c79e150d4dcf24d3e73f629ba4357149abb0 /src/textadept.c
parent3b70b4b56802f1115bd5dac04bdcb95a38c23823 (diff)
downloadtextadept-3164a7e0fb831d910c992d7e4c65d197c4e5305b.tar.gz
textadept-3164a7e0fb831d910c992d7e4c65d197c4e5305b.zip
Do not emit keys while the command entry completion is active; src/textadept.c
The GtkEntryCompletion's key handler should take precedence over GtkEntry's.
Diffstat (limited to 'src/textadept.c')
-rw-r--r--src/textadept.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/textadept.c b/src/textadept.c
index 2495a0df..4384a78c 100644
--- a/src/textadept.c
+++ b/src/textadept.c
@@ -2163,10 +2163,6 @@ static void new_window() {
gtk_box_pack_start(GTK_BOX(vbox), new_findbox(), FALSE, FALSE, 5);
- command_entry = gtk_entry_new();
- signal(command_entry, "key-press-event", c_keypress);
- gtk_box_pack_start(GTK_BOX(vbox), command_entry, FALSE, FALSE, 0);
-
command_entry_completion = gtk_entry_completion_new();
signal(command_entry_completion, "match-selected", cc_matchselected);
gtk_entry_completion_set_match_func(command_entry_completion, cc_matchfunc,
@@ -2176,9 +2172,13 @@ static void new_window() {
cc_store = gtk_list_store_new(1, G_TYPE_STRING);
gtk_entry_completion_set_model(command_entry_completion,
GTK_TREE_MODEL(cc_store));
- gtk_entry_set_completion(GTK_ENTRY(command_entry), command_entry_completion);
g_object_unref(cc_store);
+ command_entry = gtk_entry_new();
+ gtk_entry_set_completion(GTK_ENTRY(command_entry), command_entry_completion);
+ signal(command_entry, "key-press-event", c_keypress);
+ gtk_box_pack_start(GTK_BOX(vbox), command_entry, FALSE, FALSE, 0);
+
GtkWidget *hboxs = gtk_hbox_new(FALSE, 0);
gtk_box_pack_start(GTK_BOX(vbox), hboxs, FALSE, FALSE, 0);