Mercurial > pidgin
changeset 12075:f62022e07351
[gaim-migrate @ 14372]
another docklet patch from sadrul - this one fixes the scrollwheel behavior in the status message box so that it doesn't change your status.
committer: Tailor Script <tailor@pidgin.im>
author | Daniel Atallah <daniel.atallah@gmail.com> |
---|---|
date | Mon, 14 Nov 2005 01:23:36 +0000 |
parents | 950acb2bc835 |
children | 4fb1edd43f45 |
files | src/gtkstatusbox.c |
diffstat | 1 files changed, 12 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/src/gtkstatusbox.c Mon Nov 14 00:47:00 2005 +0000 +++ b/src/gtkstatusbox.c Mon Nov 14 01:23:36 2005 +0000 @@ -495,6 +495,15 @@ } +static gboolean scroll_event_cb(GtkWidget *w, GdkEventScroll *event, GtkIMHtml *imhtml) +{ + if (event->direction == GDK_SCROLL_UP) + gtk_imhtml_page_up(imhtml); + else if (event->direction == GDK_SCROLL_DOWN) + gtk_imhtml_page_down(imhtml); + return TRUE; +} + #if GTK_CHECK_VERSION(2,6,0) static gboolean dropdown_store_row_separator_func(GtkTreeModel *model, @@ -590,6 +599,9 @@ gtk_container_add(GTK_CONTAINER(status_box->sw), status_box->imhtml); gtk_box_pack_start(GTK_BOX(status_box->vbox), status_box->sw, TRUE, TRUE, 0); + g_signal_connect(G_OBJECT(status_box->imhtml), "scroll_event", + G_CALLBACK(scroll_event_cb), status_box->imhtml); + #if GTK_CHECK_VERSION(2,6,0) gtk_combo_box_set_row_separator_func(GTK_COMBO_BOX(status_box), dropdown_store_row_separator_func, NULL, NULL);