diff --git a/clutter/clutter-event.h b/clutter/clutter-event.h index 5ec8d5f03..83f7ef9cc 100644 --- a/clutter/clutter-event.h +++ b/clutter/clutter-event.h @@ -114,7 +114,7 @@ struct _ClutterKeyEvent { ClutterEventType type; guint32 time; - guint modifier_state; + ClutterModifierType modifier_state; guint keyval; guint16 hardware_keycode; }; @@ -125,7 +125,7 @@ struct _ClutterButtonEvent guint32 time; gint x; gint y; - guint32 modifier_state; + ClutterModifierType modifier_state; guint32 button; gdouble *axes; /* Future use */ ClutterInputDevice *device; /* Future use */ @@ -137,7 +137,7 @@ struct _ClutterMotionEvent guint32 time; gint x; gint y; - guint32 modifier_state; + ClutterModifierType modifier_state; gdouble *axes; /* Future use */ ClutterInputDevice *device; /* Future use */ }; @@ -149,7 +149,7 @@ struct _ClutterScrollEvent gint x; gint y; ClutterScrollDirection direction; - guint32 modifier_state; + ClutterModifierType modifier_state; gdouble *axes; /* future use */ ClutterInputDevice *device; /* future use */ }; @@ -175,19 +175,19 @@ union _ClutterEvent GType clutter_event_get_type (void) G_GNUC_CONST; -gboolean clutter_events_pending (void); -ClutterEvent * clutter_event_get (void); -ClutterEvent * clutter_event_peek (void); -void clutter_event_put (ClutterEvent *event); -ClutterEvent * clutter_event_new (ClutterEventType type); -ClutterEvent * clutter_event_copy (ClutterEvent *event); -void clutter_event_free (ClutterEvent *event); -ClutterEventType clutter_event_type (ClutterEvent *event); -guint32 clutter_event_get_time (ClutterEvent *event); -guint clutter_event_get_state (ClutterEvent *event); -void clutter_event_get_coords (ClutterEvent *event, - gint *x, - gint *y); +gboolean clutter_events_pending (void); +ClutterEvent * clutter_event_get (void); +ClutterEvent * clutter_event_peek (void); +void clutter_event_put (ClutterEvent *event); +ClutterEvent * clutter_event_new (ClutterEventType type); +ClutterEvent * clutter_event_copy (ClutterEvent *event); +void clutter_event_free (ClutterEvent *event); +ClutterEventType clutter_event_type (ClutterEvent *event); +guint32 clutter_event_get_time (ClutterEvent *event); +ClutterModifierType clutter_event_get_state (ClutterEvent *event); +void clutter_event_get_coords (ClutterEvent *event, + gint *x, + gint *y); guint clutter_key_event_symbol (ClutterKeyEvent *keyev); guint16 clutter_key_event_code (ClutterKeyEvent *keyev); diff --git a/clutter/glx/clutter-event-glx.c b/clutter/glx/clutter-event-glx.c index 49db3ec3a..7f7b28f4b 100644 --- a/clutter/glx/clutter-event-glx.c +++ b/clutter/glx/clutter-event-glx.c @@ -242,7 +242,7 @@ translate_key_event (ClutterBackend *backend, event->key.type = (xevent->xany.type == KeyPress) ? CLUTTER_KEY_PRESS : CLUTTER_KEY_RELEASE; event->key.time = xevent->xkey.time; - event->key.modifier_state = xevent->xkey.state; /* FIXME: handle modifiers */ + event->key.modifier_state = (ClutterModifierType) xevent->xkey.state; event->key.hardware_keycode = xevent->xkey.keycode; event->key.keyval = XKeycodeToKeysym (xevent->xkey.display, xevent->xkey.keycode,