Mercurial > pidgin
comparison 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 |
comparison
equal
deleted
inserted
replaced
11561:71945305a87e | 11562:9f521a61ef58 |
---|---|
29 #include "gtkgaim.h" | 29 #include "gtkgaim.h" |
30 #include "gtkstock.h" | 30 #include "gtkstock.h" |
31 #include "gtkstatusbox.h" | 31 #include "gtkstatusbox.h" |
32 | 32 |
33 static void imhtml_changed_cb(GtkTextBuffer *buffer, void *data); | 33 static void imhtml_changed_cb(GtkTextBuffer *buffer, void *data); |
34 static void remove_typing_cb(GtkGaimStatusBox *box); | |
34 | 35 |
35 static void gtk_gaim_status_box_changed(GtkComboBox *box); | 36 static void gtk_gaim_status_box_changed(GtkComboBox *box); |
36 static void gtk_gaim_status_box_size_request (GtkWidget *widget, GtkRequisition *requisition); | 37 static void gtk_gaim_status_box_size_request (GtkWidget *widget, GtkRequisition *requisition); |
37 static void gtk_gaim_status_box_size_allocate (GtkWidget *widget, GtkAllocation *allocation); | 38 static void gtk_gaim_status_box_size_allocate (GtkWidget *widget, GtkAllocation *allocation); |
38 static gboolean gtk_gaim_status_box_expose_event (GtkWidget *widget, GdkEventExpose *event); | 39 static gboolean gtk_gaim_status_box_expose_event (GtkWidget *widget, GdkEventExpose *event); |
279 | 280 |
280 status_box->vbox = gtk_vbox_new(0, FALSE); | 281 status_box->vbox = gtk_vbox_new(0, FALSE); |
281 status_box->imhtml = gtk_imhtml_new(NULL, NULL); | 282 status_box->imhtml = gtk_imhtml_new(NULL, NULL); |
282 buffer = gtk_text_view_get_buffer(GTK_TEXT_VIEW(status_box->imhtml)); | 283 buffer = gtk_text_view_get_buffer(GTK_TEXT_VIEW(status_box->imhtml)); |
283 g_signal_connect(G_OBJECT(buffer), "changed", G_CALLBACK(imhtml_changed_cb), status_box); | 284 g_signal_connect(G_OBJECT(buffer), "changed", G_CALLBACK(imhtml_changed_cb), status_box); |
285 g_signal_connect_swapped(G_OBJECT(status_box->imhtml), "message_send", G_CALLBACK(remove_typing_cb), status_box); | |
284 gtk_imhtml_set_editable(GTK_IMHTML(status_box->imhtml), TRUE); | 286 gtk_imhtml_set_editable(GTK_IMHTML(status_box->imhtml), TRUE); |
285 gtk_widget_set_parent(status_box->vbox, GTK_WIDGET(status_box)); | 287 gtk_widget_set_parent(status_box->vbox, GTK_WIDGET(status_box)); |
286 status_box->sw = gtk_scrolled_window_new(NULL, NULL); | 288 status_box->sw = gtk_scrolled_window_new(NULL, NULL); |
287 gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(status_box->sw), GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC); | 289 gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(status_box->sw), GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC); |
288 gtk_scrolled_window_set_shadow_type(GTK_SCROLLED_WINDOW(status_box->sw), GTK_SHADOW_IN); | 290 gtk_scrolled_window_set_shadow_type(GTK_SCROLLED_WINDOW(status_box->sw), GTK_SHADOW_IN); |