Orca would sometimes fail to notice that its modifier key was released
since it was presumed to be hung and would not be sent the event. So,
rather than ignore event listeners assumed to be hung, we'll send them
the notifications for the keys that they're listening to but not wait
for a reply, instead assuming that they are not consumed.
DBusError error;
dbus_bool_t consumed = FALSE;
GSList *l;
+ gboolean hung = FALSE;
for (l = hung_processes; l; l = l->next)
{
if (!strcmp (l->data, listener->bus_name))
{
- dbus_message_unref (message);
- return FALSE;
+ dbus_message_set_no_reply (message, TRUE);
+ hung = TRUE;
+ break;
}
}
dbus_error_init(&error);
if (spi_dbus_marshal_deviceEvent(message, key_event))
{
+ if (hung)
+ {
+ dbus_connection_send (controller->bus, message, NULL);
+ dbus_message_unref (message);
+ return FALSE;
+ }
DBusMessage *reply = send_and_allow_reentry (controller->bus, message, 1000, &error);
if (reply)
{