Fix press/release confusion when synthesizing clutter key events

We were generating presses for releases and vice-versa.

https://bugzilla.gnome.org/show_bug.cgi?id=641896
This commit is contained in:
Takao Fujiwara 2011-02-09 14:00:47 +09:00 committed by Owen W. Taylor
parent 881a1d5cbc
commit 1f154f6638

View File

@ -368,7 +368,7 @@ gnome_shell_gdk_event_handler (GdkEvent *event_gdk,
ClutterInputDevice *keyboard = clutter_device_manager_get_core_device (device_manager,
CLUTTER_KEYBOARD_DEVICE);
ClutterEvent *event_clutter = clutter_event_new ((event_gdk->type == GDK_KEY_RELEASE) ?
ClutterEvent *event_clutter = clutter_event_new ((event_gdk->type == GDK_KEY_PRESS) ?
CLUTTER_KEY_PRESS : CLUTTER_KEY_RELEASE);
event_clutter->key.time = event_gdk->key.time;
event_clutter->key.flags = CLUTTER_EVENT_NONE;