diff --git a/ChangeLog b/ChangeLog index 8f3acf0ca2..9068232a4f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,17 @@ +Mon Feb 16 23:47:09 1998 Owen Taylor + + * gtk/gtkviewport.c: (gtk-fortier-980130-0) + From Patrice Fortier + + Eliminate some extra expose events for viewports. + (To be conservative, I set the user's event mask for + both widget->window, and viewport->bin_window -owt) + +Mon Feb 16 23:12:14 1998 Owen Taylor + + * gtk/gtkmain.c: Make timeout and idle insertion code + use g_list_insert_sorted(). + Mon Feb 16 17:35:17 1998 Owen Taylor * gtk/gtktreeitem.c: Use gtk_signal_default_marshaller, diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0 index 8f3acf0ca2..9068232a4f 100644 --- a/ChangeLog.pre-2-0 +++ b/ChangeLog.pre-2-0 @@ -1,3 +1,17 @@ +Mon Feb 16 23:47:09 1998 Owen Taylor + + * gtk/gtkviewport.c: (gtk-fortier-980130-0) + From Patrice Fortier + + Eliminate some extra expose events for viewports. + (To be conservative, I set the user's event mask for + both widget->window, and viewport->bin_window -owt) + +Mon Feb 16 23:12:14 1998 Owen Taylor + + * gtk/gtkmain.c: Make timeout and idle insertion code + use g_list_insert_sorted(). + Mon Feb 16 17:35:17 1998 Owen Taylor * gtk/gtktreeitem.c: Use gtk_signal_default_marshaller, diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 8f3acf0ca2..9068232a4f 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,17 @@ +Mon Feb 16 23:47:09 1998 Owen Taylor + + * gtk/gtkviewport.c: (gtk-fortier-980130-0) + From Patrice Fortier + + Eliminate some extra expose events for viewports. + (To be conservative, I set the user's event mask for + both widget->window, and viewport->bin_window -owt) + +Mon Feb 16 23:12:14 1998 Owen Taylor + + * gtk/gtkmain.c: Make timeout and idle insertion code + use g_list_insert_sorted(). + Mon Feb 16 17:35:17 1998 Owen Taylor * gtk/gtktreeitem.c: Use gtk_signal_default_marshaller, diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2 index 8f3acf0ca2..9068232a4f 100644 --- a/ChangeLog.pre-2-2 +++ b/ChangeLog.pre-2-2 @@ -1,3 +1,17 @@ +Mon Feb 16 23:47:09 1998 Owen Taylor + + * gtk/gtkviewport.c: (gtk-fortier-980130-0) + From Patrice Fortier + + Eliminate some extra expose events for viewports. + (To be conservative, I set the user's event mask for + both widget->window, and viewport->bin_window -owt) + +Mon Feb 16 23:12:14 1998 Owen Taylor + + * gtk/gtkmain.c: Make timeout and idle insertion code + use g_list_insert_sorted(). + Mon Feb 16 17:35:17 1998 Owen Taylor * gtk/gtktreeitem.c: Use gtk_signal_default_marshaller, diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index 8f3acf0ca2..9068232a4f 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,3 +1,17 @@ +Mon Feb 16 23:47:09 1998 Owen Taylor + + * gtk/gtkviewport.c: (gtk-fortier-980130-0) + From Patrice Fortier + + Eliminate some extra expose events for viewports. + (To be conservative, I set the user's event mask for + both widget->window, and viewport->bin_window -owt) + +Mon Feb 16 23:12:14 1998 Owen Taylor + + * gtk/gtkmain.c: Make timeout and idle insertion code + use g_list_insert_sorted(). + Mon Feb 16 17:35:17 1998 Owen Taylor * gtk/gtktreeitem.c: Use gtk_signal_default_marshaller, diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index 8f3acf0ca2..9068232a4f 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,17 @@ +Mon Feb 16 23:47:09 1998 Owen Taylor + + * gtk/gtkviewport.c: (gtk-fortier-980130-0) + From Patrice Fortier + + Eliminate some extra expose events for viewports. + (To be conservative, I set the user's event mask for + both widget->window, and viewport->bin_window -owt) + +Mon Feb 16 23:12:14 1998 Owen Taylor + + * gtk/gtkmain.c: Make timeout and idle insertion code + use g_list_insert_sorted(). + Mon Feb 16 17:35:17 1998 Owen Taylor * gtk/gtktreeitem.c: Use gtk_signal_default_marshaller, diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index 8f3acf0ca2..9068232a4f 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,17 @@ +Mon Feb 16 23:47:09 1998 Owen Taylor + + * gtk/gtkviewport.c: (gtk-fortier-980130-0) + From Patrice Fortier + + Eliminate some extra expose events for viewports. + (To be conservative, I set the user's event mask for + both widget->window, and viewport->bin_window -owt) + +Mon Feb 16 23:12:14 1998 Owen Taylor + + * gtk/gtkmain.c: Make timeout and idle insertion code + use g_list_insert_sorted(). + Mon Feb 16 17:35:17 1998 Owen Taylor * gtk/gtktreeitem.c: Use gtk_signal_default_marshaller, diff --git a/gtk/gtkviewport.c b/gtk/gtkviewport.c index cf04127dde..08e5d27a28 100644 --- a/gtk/gtkviewport.c +++ b/gtk/gtkviewport.c @@ -281,6 +281,7 @@ gtk_viewport_realize (GtkWidget *widget) GdkWindowAttr attributes; GtkRequisition *child_requisition; gint attributes_mask; + gint event_mask; g_return_if_fail (widget != NULL); g_return_if_fail (GTK_IS_VIEWPORT (widget)); @@ -297,7 +298,9 @@ gtk_viewport_realize (GtkWidget *widget) attributes.wclass = GDK_INPUT_OUTPUT; attributes.visual = gtk_widget_get_visual (widget); attributes.colormap = gtk_widget_get_colormap (widget); - attributes.event_mask = gtk_widget_get_events (widget) | GDK_EXPOSURE_MASK; + + event_mask = gtk_widget_get_events (widget) | GDK_EXPOSURE_MASK; + attributes.event_mask = event_mask; attributes_mask = GDK_WA_X | GDK_WA_Y | GDK_WA_VISUAL | GDK_WA_COLORMAP; @@ -309,12 +312,14 @@ gtk_viewport_realize (GtkWidget *widget) attributes.y += widget->style->klass->ythickness; attributes.width -= widget->style->klass->xthickness * 2; attributes.height -= widget->style->klass->ythickness * 2; + attributes.event_mask = 0; viewport->view_window = gdk_window_new (widget->window, &attributes, attributes_mask); gdk_window_set_user_data (viewport->view_window, viewport); attributes.x = 0; attributes.y = 0; + attributes.event_mask = event_mask; viewport->bin_window = gdk_window_new (viewport->view_window, &attributes, attributes_mask); gdk_window_set_user_data (viewport->bin_window, viewport); @@ -431,7 +436,8 @@ gtk_viewport_expose (GtkWidget *widget, gtk_viewport_paint (widget, &event->area); child_event = *event; - if (bin->child && + if ((event->window == viewport->bin_window) && + (bin->child != NULL) && GTK_WIDGET_NO_WINDOW (bin->child) && gtk_widget_intersect (bin->child, &event->area, &child_event.area)) gtk_widget_event (bin->child, (GdkEvent*) &child_event);