diff src/gtkstatusbox.c @ 11562:9f521a61ef58

[gaim-migrate @ 13828] More tiny changes. Forward port my saving password through failed connections change, and attach to the Message Send signal of the statusbox imhtml, so that hitting Enter sets the message immediately. I like the timeout; but this will probably make more sense to most people. committer: Tailor Script <tailor@pidgin.im>
author Sean Egan <seanegan@gmail.com>
date Wed, 21 Sep 2005 22:57:10 +0000
parents 1116993aadd2
children 4b7fb30b8926
line wrap: on
line diff
--- a/src/gtkstatusbox.c	Wed Sep 21 02:05:08 2005 +0000
+++ b/src/gtkstatusbox.c	Wed Sep 21 22:57:10 2005 +0000
@@ -31,6 +31,7 @@
 #include "gtkstatusbox.h"
 
 static void imhtml_changed_cb(GtkTextBuffer *buffer, void *data);
+static void remove_typing_cb(GtkGaimStatusBox *box);
 
 static void gtk_gaim_status_box_changed(GtkComboBox *box);
 static void gtk_gaim_status_box_size_request (GtkWidget *widget, GtkRequisition *requisition);
@@ -281,6 +282,7 @@
 	status_box->imhtml = gtk_imhtml_new(NULL, NULL);
 	buffer = gtk_text_view_get_buffer(GTK_TEXT_VIEW(status_box->imhtml));
 	g_signal_connect(G_OBJECT(buffer), "changed", G_CALLBACK(imhtml_changed_cb), status_box);
+	g_signal_connect_swapped(G_OBJECT(status_box->imhtml), "message_send", G_CALLBACK(remove_typing_cb), status_box);
 	gtk_imhtml_set_editable(GTK_IMHTML(status_box->imhtml), TRUE);
 	gtk_widget_set_parent(status_box->vbox, GTK_WIDGET(status_box));
 	status_box->sw = gtk_scrolled_window_new(NULL, NULL);