summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--text_input_dialog.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/text_input_dialog.c b/text_input_dialog.c
index da18b24..8a77692 100644
--- a/text_input_dialog.c
+++ b/text_input_dialog.c
@@ -7,7 +7,10 @@ GtkDialog *text_input_dialog_new(GtkWidget *parent, const gchar *msg) {
dialog = gtk_message_dialog_new(GTK_WINDOW(parent), GTK_DIALOG_MODAL | GTK_DIALOG_DESTROY_WITH_PARENT,
GTK_MESSAGE_QUESTION, GTK_BUTTONS_OK_CANCEL, msg);
+ gtk_dialog_set_default_response(GTK_DIALOG(dialog), GTK_RESPONSE_OK);
+
entry = gtk_entry_new();
+ gtk_entry_set_activates_default(GTK_ENTRY(entry), TRUE);
vbox = gtk_dialog_get_content_area(GTK_DIALOG(dialog));
gtk_box_pack_end(GTK_BOX(vbox), entry, FALSE, FALSE, 0);