diff options
author | Federico Mena Quintero <federico@nuclecu.unam.mx> | 1998-05-27 02:01:40 +0000 |
---|---|---|
committer | Arturo Espinosa <unammx@src.gnome.org> | 1998-05-27 02:01:40 +0000 |
commit | 99fdc828ebb377bc8317c58328ae4df678d85148 (patch) | |
tree | 4ee3c55d5f4ba9afbde88583288d9a54e0967dea | |
parent | d6d54509d3f3b2087e709aa18900c37683844718 (diff) | |
download | gtk+-99fdc828ebb377bc8317c58328ae4df678d85148.tar.gz |
New enumeration for the "mode" field of crossing events. (struct
1998-05-26 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gdk/gdktypes.h (GdkCrossingMode): New enumeration for the "mode"
field of crossing events.
(struct _GdkEventCrossing): Added the following fields: time, x,
y, x_root, y_root, mode, focus, state.
* gdk/gdk.c (gdk_event_translate): Fill in the new fields of the
crossing event structure.
* gtk/gtkfeatures.h (GDK_HAVE_FULL_CROSSING_EVENT): Annotate
changes to the crossing event structure.
-rw-r--r-- | ChangeLog | 13 | ||||
-rw-r--r-- | ChangeLog.pre-2-0 | 13 | ||||
-rw-r--r-- | ChangeLog.pre-2-10 | 13 | ||||
-rw-r--r-- | ChangeLog.pre-2-2 | 13 | ||||
-rw-r--r-- | ChangeLog.pre-2-4 | 13 | ||||
-rw-r--r-- | ChangeLog.pre-2-6 | 13 | ||||
-rw-r--r-- | ChangeLog.pre-2-8 | 13 | ||||
-rw-r--r-- | gdk/gdk.c | 49 | ||||
-rw-r--r-- | gdk/gdktypes.h | 20 | ||||
-rw-r--r-- | gdk/x11/gdkmain-x11.c | 49 |
10 files changed, 209 insertions, 0 deletions
@@ -1,3 +1,16 @@ +1998-05-26 Federico Mena Quintero <federico@nuclecu.unam.mx> + + * gdk/gdktypes.h (GdkCrossingMode): New enumeration for the "mode" + field of crossing events. + (struct _GdkEventCrossing): Added the following fields: time, x, + y, x_root, y_root, mode, focus, state. + + * gdk/gdk.c (gdk_event_translate): Fill in the new fields of the + crossing event structure. + + * gtk/gtkfeatures.h (GDK_HAVE_FULL_CROSSING_EVENT): Annotate + changes to the crossing event structure. + Tue May 26 15:51:28 1998 Radek Doulik <gis@academy.cas.cz> * gdk/gdk.c: include gdkx.h always (for GDK_ROOT_WINDOW) diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0 index 63934644fd..103eb27419 100644 --- a/ChangeLog.pre-2-0 +++ b/ChangeLog.pre-2-0 @@ -1,3 +1,16 @@ +1998-05-26 Federico Mena Quintero <federico@nuclecu.unam.mx> + + * gdk/gdktypes.h (GdkCrossingMode): New enumeration for the "mode" + field of crossing events. + (struct _GdkEventCrossing): Added the following fields: time, x, + y, x_root, y_root, mode, focus, state. + + * gdk/gdk.c (gdk_event_translate): Fill in the new fields of the + crossing event structure. + + * gtk/gtkfeatures.h (GDK_HAVE_FULL_CROSSING_EVENT): Annotate + changes to the crossing event structure. + Tue May 26 15:51:28 1998 Radek Doulik <gis@academy.cas.cz> * gdk/gdk.c: include gdkx.h always (for GDK_ROOT_WINDOW) diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 63934644fd..103eb27419 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,16 @@ +1998-05-26 Federico Mena Quintero <federico@nuclecu.unam.mx> + + * gdk/gdktypes.h (GdkCrossingMode): New enumeration for the "mode" + field of crossing events. + (struct _GdkEventCrossing): Added the following fields: time, x, + y, x_root, y_root, mode, focus, state. + + * gdk/gdk.c (gdk_event_translate): Fill in the new fields of the + crossing event structure. + + * gtk/gtkfeatures.h (GDK_HAVE_FULL_CROSSING_EVENT): Annotate + changes to the crossing event structure. + Tue May 26 15:51:28 1998 Radek Doulik <gis@academy.cas.cz> * gdk/gdk.c: include gdkx.h always (for GDK_ROOT_WINDOW) diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2 index 63934644fd..103eb27419 100644 --- a/ChangeLog.pre-2-2 +++ b/ChangeLog.pre-2-2 @@ -1,3 +1,16 @@ +1998-05-26 Federico Mena Quintero <federico@nuclecu.unam.mx> + + * gdk/gdktypes.h (GdkCrossingMode): New enumeration for the "mode" + field of crossing events. + (struct _GdkEventCrossing): Added the following fields: time, x, + y, x_root, y_root, mode, focus, state. + + * gdk/gdk.c (gdk_event_translate): Fill in the new fields of the + crossing event structure. + + * gtk/gtkfeatures.h (GDK_HAVE_FULL_CROSSING_EVENT): Annotate + changes to the crossing event structure. + Tue May 26 15:51:28 1998 Radek Doulik <gis@academy.cas.cz> * gdk/gdk.c: include gdkx.h always (for GDK_ROOT_WINDOW) diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index 63934644fd..103eb27419 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,3 +1,16 @@ +1998-05-26 Federico Mena Quintero <federico@nuclecu.unam.mx> + + * gdk/gdktypes.h (GdkCrossingMode): New enumeration for the "mode" + field of crossing events. + (struct _GdkEventCrossing): Added the following fields: time, x, + y, x_root, y_root, mode, focus, state. + + * gdk/gdk.c (gdk_event_translate): Fill in the new fields of the + crossing event structure. + + * gtk/gtkfeatures.h (GDK_HAVE_FULL_CROSSING_EVENT): Annotate + changes to the crossing event structure. + Tue May 26 15:51:28 1998 Radek Doulik <gis@academy.cas.cz> * gdk/gdk.c: include gdkx.h always (for GDK_ROOT_WINDOW) diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index 63934644fd..103eb27419 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,16 @@ +1998-05-26 Federico Mena Quintero <federico@nuclecu.unam.mx> + + * gdk/gdktypes.h (GdkCrossingMode): New enumeration for the "mode" + field of crossing events. + (struct _GdkEventCrossing): Added the following fields: time, x, + y, x_root, y_root, mode, focus, state. + + * gdk/gdk.c (gdk_event_translate): Fill in the new fields of the + crossing event structure. + + * gtk/gtkfeatures.h (GDK_HAVE_FULL_CROSSING_EVENT): Annotate + changes to the crossing event structure. + Tue May 26 15:51:28 1998 Radek Doulik <gis@academy.cas.cz> * gdk/gdk.c: include gdkx.h always (for GDK_ROOT_WINDOW) diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index 63934644fd..103eb27419 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,16 @@ +1998-05-26 Federico Mena Quintero <federico@nuclecu.unam.mx> + + * gdk/gdktypes.h (GdkCrossingMode): New enumeration for the "mode" + field of crossing events. + (struct _GdkEventCrossing): Added the following fields: time, x, + y, x_root, y_root, mode, focus, state. + + * gdk/gdk.c (gdk_event_translate): Fill in the new fields of the + crossing event structure. + + * gtk/gtkfeatures.h (GDK_HAVE_FULL_CROSSING_EVENT): Annotate + changes to the crossing event structure. + Tue May 26 15:51:28 1998 Radek Doulik <gis@academy.cas.cz> * gdk/gdk.c: include gdkx.h always (for GDK_ROOT_WINDOW) @@ -2291,6 +2291,27 @@ gdk_event_translate (GdkEvent *event, else event->crossing.subwindow = NULL; + event->crossing.time = xevent->xcrossing.time; + event->crossing.x = xevent->xcrossing.x; + event->crossing.y = xevent->xcrossing.y; + event->crossing.x_root = xevent->xcrossing.x_root; + event->crossing.y_root = xevent->xcrossing.y_root; + + /* Translate the crossing mode into Gdk terms. + */ + switch (xevent->xcrossing.mode) + { + case NotifyNormal: + event->crossing.mode = GDK_CROSSING_NORMAL; + break; + case NotifyGrab: + event->crossing.mode = GDK_CROSSING_GRAB; + break; + case NotifyUngrab: + event->crossing.mode = GDK_CROSSING_UNGRAB; + break; + }; + /* Translate the crossing detail into Gdk terms. */ switch (xevent->xcrossing.detail) @@ -2315,6 +2336,9 @@ gdk_event_translate (GdkEvent *event, break; } + event->crossing.focus = xevent->xcrossing.focus; + event->crossing.state = xevent->xcrossing.state; + #ifdef G_ENABLE_DEBUG if ((gdk_debug_flags & GDK_DEBUG_DND) & gdk_dnd.drag_perhaps) { @@ -2365,6 +2389,27 @@ gdk_event_translate (GdkEvent *event, else event->crossing.subwindow = NULL; + event->crossing.time = xevent->xcrossing.time; + event->crossing.x = xevent->xcrossing.x; + event->crossing.y = xevent->xcrossing.y; + event->crossing.x_root = xevent->xcrossing.x_root; + event->crossing.y_root = xevent->xcrossing.y_root; + + /* Translate the crossing mode into Gdk terms. + */ + switch (xevent->xcrossing.mode) + { + case NotifyNormal: + event->crossing.mode = GDK_CROSSING_NORMAL; + break; + case NotifyGrab: + event->crossing.mode = GDK_CROSSING_GRAB; + break; + case NotifyUngrab: + event->crossing.mode = GDK_CROSSING_UNGRAB; + break; + }; + /* Translate the crossing detail into Gdk terms. */ switch (xevent->xcrossing.detail) @@ -2388,6 +2433,10 @@ gdk_event_translate (GdkEvent *event, event->crossing.detail = GDK_NOTIFY_UNKNOWN; break; } + + event->crossing.focus = xevent->xcrossing.focus; + event->crossing.state = xevent->xcrossing.state; + #ifdef G_ENABLE_DEBUG if ((gdk_debug_flags & GDK_DEBUG_DND) & gdk_dnd.drag_perhaps) { diff --git a/gdk/gdktypes.h b/gdk/gdktypes.h index 8b39365ba8..2be67de5d6 100644 --- a/gdk/gdktypes.h +++ b/gdk/gdktypes.h @@ -412,6 +412,18 @@ typedef enum GDK_NOTIFY_UNKNOWN = 5 } GdkNotifyType; +/* Enter/leave event modes. + * NotifyNormal + * NotifyGrab + * NotifyUngrab + */ +typedef enum +{ + GDK_CROSSING_NORMAL, + GDK_CROSSING_GRAB, + GDK_CROSSING_UNGRAB +} GdkCrossingMode; + /* Types of modifiers. */ typedef enum @@ -999,7 +1011,15 @@ struct _GdkEventCrossing GdkWindow *window; gint8 send_event; GdkWindow *subwindow; + guint32 time; + gdouble x; + gdouble y; + gdouble x_root; + gdouble y_root; + GdkCrossingMode mode; GdkNotifyType detail; + gboolean focus; + guint state; }; struct _GdkEventFocus diff --git a/gdk/x11/gdkmain-x11.c b/gdk/x11/gdkmain-x11.c index 8e05fd57af..2303b293fd 100644 --- a/gdk/x11/gdkmain-x11.c +++ b/gdk/x11/gdkmain-x11.c @@ -2291,6 +2291,27 @@ gdk_event_translate (GdkEvent *event, else event->crossing.subwindow = NULL; + event->crossing.time = xevent->xcrossing.time; + event->crossing.x = xevent->xcrossing.x; + event->crossing.y = xevent->xcrossing.y; + event->crossing.x_root = xevent->xcrossing.x_root; + event->crossing.y_root = xevent->xcrossing.y_root; + + /* Translate the crossing mode into Gdk terms. + */ + switch (xevent->xcrossing.mode) + { + case NotifyNormal: + event->crossing.mode = GDK_CROSSING_NORMAL; + break; + case NotifyGrab: + event->crossing.mode = GDK_CROSSING_GRAB; + break; + case NotifyUngrab: + event->crossing.mode = GDK_CROSSING_UNGRAB; + break; + }; + /* Translate the crossing detail into Gdk terms. */ switch (xevent->xcrossing.detail) @@ -2315,6 +2336,9 @@ gdk_event_translate (GdkEvent *event, break; } + event->crossing.focus = xevent->xcrossing.focus; + event->crossing.state = xevent->xcrossing.state; + #ifdef G_ENABLE_DEBUG if ((gdk_debug_flags & GDK_DEBUG_DND) & gdk_dnd.drag_perhaps) { @@ -2365,6 +2389,27 @@ gdk_event_translate (GdkEvent *event, else event->crossing.subwindow = NULL; + event->crossing.time = xevent->xcrossing.time; + event->crossing.x = xevent->xcrossing.x; + event->crossing.y = xevent->xcrossing.y; + event->crossing.x_root = xevent->xcrossing.x_root; + event->crossing.y_root = xevent->xcrossing.y_root; + + /* Translate the crossing mode into Gdk terms. + */ + switch (xevent->xcrossing.mode) + { + case NotifyNormal: + event->crossing.mode = GDK_CROSSING_NORMAL; + break; + case NotifyGrab: + event->crossing.mode = GDK_CROSSING_GRAB; + break; + case NotifyUngrab: + event->crossing.mode = GDK_CROSSING_UNGRAB; + break; + }; + /* Translate the crossing detail into Gdk terms. */ switch (xevent->xcrossing.detail) @@ -2388,6 +2433,10 @@ gdk_event_translate (GdkEvent *event, event->crossing.detail = GDK_NOTIFY_UNKNOWN; break; } + + event->crossing.focus = xevent->xcrossing.focus; + event->crossing.state = xevent->xcrossing.state; + #ifdef G_ENABLE_DEBUG if ((gdk_debug_flags & GDK_DEBUG_DND) & gdk_dnd.drag_perhaps) { |