forked from AuroraMiddleware/gtk
Allow focus-change events to be sent to unrealized widgets; they aren't
Wed Feb 27 18:50:29 2002 Owen Taylor <otaylor@redhat.com> * gtk/gtkwidget.c (gtk_widget_event): Allow focus-change events to be sent to unrealized widgets; they aren't really normal events in that they have anything to do with widget->window. (#72914)
This commit is contained in:
parent
8ba3ebdef8
commit
531861fb8f
@ -1,3 +1,10 @@
|
||||
Wed Feb 27 18:50:29 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/gtkwidget.c (gtk_widget_event): Allow focus-change
|
||||
events to be sent to unrealized widgets; they aren't
|
||||
really normal events in that they have anything to
|
||||
do with widget->window. (#72914)
|
||||
|
||||
Wed Feb 27 18:39:25 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/stock-icons/Makefile.am: Split big VARIABLES variable
|
||||
|
@ -1,3 +1,10 @@
|
||||
Wed Feb 27 18:50:29 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/gtkwidget.c (gtk_widget_event): Allow focus-change
|
||||
events to be sent to unrealized widgets; they aren't
|
||||
really normal events in that they have anything to
|
||||
do with widget->window. (#72914)
|
||||
|
||||
Wed Feb 27 18:39:25 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/stock-icons/Makefile.am: Split big VARIABLES variable
|
||||
|
@ -1,3 +1,10 @@
|
||||
Wed Feb 27 18:50:29 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/gtkwidget.c (gtk_widget_event): Allow focus-change
|
||||
events to be sent to unrealized widgets; they aren't
|
||||
really normal events in that they have anything to
|
||||
do with widget->window. (#72914)
|
||||
|
||||
Wed Feb 27 18:39:25 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/stock-icons/Makefile.am: Split big VARIABLES variable
|
||||
|
@ -1,3 +1,10 @@
|
||||
Wed Feb 27 18:50:29 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/gtkwidget.c (gtk_widget_event): Allow focus-change
|
||||
events to be sent to unrealized widgets; they aren't
|
||||
really normal events in that they have anything to
|
||||
do with widget->window. (#72914)
|
||||
|
||||
Wed Feb 27 18:39:25 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/stock-icons/Makefile.am: Split big VARIABLES variable
|
||||
|
@ -1,3 +1,10 @@
|
||||
Wed Feb 27 18:50:29 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/gtkwidget.c (gtk_widget_event): Allow focus-change
|
||||
events to be sent to unrealized widgets; they aren't
|
||||
really normal events in that they have anything to
|
||||
do with widget->window. (#72914)
|
||||
|
||||
Wed Feb 27 18:39:25 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/stock-icons/Makefile.am: Split big VARIABLES variable
|
||||
|
@ -1,3 +1,10 @@
|
||||
Wed Feb 27 18:50:29 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/gtkwidget.c (gtk_widget_event): Allow focus-change
|
||||
events to be sent to unrealized widgets; they aren't
|
||||
really normal events in that they have anything to
|
||||
do with widget->window. (#72914)
|
||||
|
||||
Wed Feb 27 18:39:25 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/stock-icons/Makefile.am: Split big VARIABLES variable
|
||||
|
@ -1,3 +1,10 @@
|
||||
Wed Feb 27 18:50:29 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/gtkwidget.c (gtk_widget_event): Allow focus-change
|
||||
events to be sent to unrealized widgets; they aren't
|
||||
really normal events in that they have anything to
|
||||
do with widget->window. (#72914)
|
||||
|
||||
Wed Feb 27 18:39:25 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/stock-icons/Makefile.am: Split big VARIABLES variable
|
||||
|
@ -2896,6 +2896,9 @@ gtk_widget_real_focus_out_event (GtkWidget *widget,
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
#define WIDGET_REALIZED_FOR_EVENT(widget, event) \
|
||||
(event->type == GDK_FOCUS_CHANGE || GTK_WIDGET_REALIZED(widget))
|
||||
|
||||
/**
|
||||
* gtk_widget_event:
|
||||
* @widget: a #GtkWidget
|
||||
@ -2917,7 +2920,7 @@ gtk_widget_event (GtkWidget *widget,
|
||||
GdkEvent *event)
|
||||
{
|
||||
g_return_val_if_fail (GTK_IS_WIDGET (widget), TRUE);
|
||||
g_return_val_if_fail (GTK_WIDGET_REALIZED (widget), TRUE);
|
||||
g_return_val_if_fail (WIDGET_REALIZED_FOR_EVENT (widget, event), TRUE);
|
||||
|
||||
if (event->type == GDK_EXPOSE)
|
||||
{
|
||||
@ -2973,7 +2976,7 @@ gtk_widget_event_internal (GtkWidget *widget,
|
||||
gtk_widget_ref (widget);
|
||||
|
||||
gtk_signal_emit (GTK_OBJECT (widget), widget_signals[EVENT], event, &return_val);
|
||||
return_val |= !GTK_WIDGET_REALIZED (widget);
|
||||
return_val |= !WIDGET_REALIZED_FOR_EVENT (widget, event);
|
||||
if (!return_val)
|
||||
{
|
||||
gint signal_num;
|
||||
@ -3068,7 +3071,7 @@ gtk_widget_event_internal (GtkWidget *widget,
|
||||
if (signal_num != -1)
|
||||
gtk_signal_emit (GTK_OBJECT (widget), widget_signals[signal_num], event, &return_val);
|
||||
}
|
||||
if (GTK_WIDGET_REALIZED (widget))
|
||||
if (WIDGET_REALIZED_FOR_EVENT (widget, event))
|
||||
gtk_signal_emit (GTK_OBJECT (widget), widget_signals[EVENT_AFTER], event);
|
||||
else
|
||||
return_val = TRUE;
|
||||
|
Loading…
Reference in New Issue
Block a user