Special case scroll events so that they propagate up the widget heirarchy

Wed Mar  3 17:20:15 2004  Owen Taylor  <otaylor@redhat.com>

        * gtk/gtkmain.c (gtk_propagate_event): Special case
        scroll events so that they propagate up the widget
        heirarchy when received on insensitive widgets.
        (#101102, reported by Geoff Reedy)
This commit is contained in:
Owen Taylor 2004-03-03 22:27:11 +00:00 committed by Owen Taylor
parent 0d898ffc6a
commit 7a9bec2891
6 changed files with 46 additions and 2 deletions

View File

@ -1,3 +1,10 @@
Wed Mar 3 17:20:15 2004 Owen Taylor <otaylor@redhat.com>
* gtk/gtkmain.c (gtk_propagate_event): Special case
scroll events so that they propagate up the widget
heirarchy when received on insensitive widgets.
(#101102, reported by Geoff Reedy)
Wed Mar 3 16:47:10 2004 Owen Taylor <otaylor@redhat.com>
#109594, reported by Olivier Ripoll

View File

@ -1,3 +1,10 @@
Wed Mar 3 17:20:15 2004 Owen Taylor <otaylor@redhat.com>
* gtk/gtkmain.c (gtk_propagate_event): Special case
scroll events so that they propagate up the widget
heirarchy when received on insensitive widgets.
(#101102, reported by Geoff Reedy)
Wed Mar 3 16:47:10 2004 Owen Taylor <otaylor@redhat.com>
#109594, reported by Olivier Ripoll

View File

@ -1,3 +1,10 @@
Wed Mar 3 17:20:15 2004 Owen Taylor <otaylor@redhat.com>
* gtk/gtkmain.c (gtk_propagate_event): Special case
scroll events so that they propagate up the widget
heirarchy when received on insensitive widgets.
(#101102, reported by Geoff Reedy)
Wed Mar 3 16:47:10 2004 Owen Taylor <otaylor@redhat.com>
#109594, reported by Olivier Ripoll

View File

@ -1,3 +1,10 @@
Wed Mar 3 17:20:15 2004 Owen Taylor <otaylor@redhat.com>
* gtk/gtkmain.c (gtk_propagate_event): Special case
scroll events so that they propagate up the widget
heirarchy when received on insensitive widgets.
(#101102, reported by Geoff Reedy)
Wed Mar 3 16:47:10 2004 Owen Taylor <otaylor@redhat.com>
#109594, reported by Olivier Ripoll

View File

@ -1,3 +1,10 @@
Wed Mar 3 17:20:15 2004 Owen Taylor <otaylor@redhat.com>
* gtk/gtkmain.c (gtk_propagate_event): Special case
scroll events so that they propagate up the widget
heirarchy when received on insensitive widgets.
(#101102, reported by Geoff Reedy)
Wed Mar 3 16:47:10 2004 Owen Taylor <otaylor@redhat.com>
#109594, reported by Olivier Ripoll

View File

@ -2331,8 +2331,17 @@ gtk_propagate_event (GtkWidget *widget,
while (TRUE)
{
GtkWidget *tmp;
handled_event = !GTK_WIDGET_IS_SENSITIVE (widget) || gtk_widget_event (widget, event);
/* Scroll events are special cased here because it
* feels wrong when scrolling a GtkViewport, say,
* to have children of the viewport eat the scroll
* event
*/
if (!GTK_WIDGET_IS_SENSITIVE (widget))
handled_event = event->type != GDK_SCROLL;
else
handled_event = gtk_widget_event (widget, event);
tmp = widget->parent;
g_object_unref (widget);