[g-a-devel]Patch for bug 93658
- From: "Padraig O'Briain" <Padraig Obriain Sun COM>
- To: gnome-accessibility-devel gnome org
- Subject: [g-a-devel]Patch for bug 93658
- Date: Tue, 8 Oct 2002 10:22:11 +0100 (BST)
Bug 93658 is ALL_WINDOWS key listeners always consume keys.
Attached is a proposed patch.
Padraig
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/at-spi/ChangeLog,v
retrieving revision 1.247
diff -u -p -r1.247 ChangeLog
--- ChangeLog 8 Oct 2002 08:53:58 -0000 1.247
+++ ChangeLog 8 Oct 2002 09:20:54 -0000
@@ -1,5 +1,15 @@
2002-10-08 Padraig O'Briain <padraig obriain sun com>
+ * registryd/deviceeventcontroller.c
+ (global_filter_fn): Correct typo which caused Keypress and KeyRelease
+ events to be ignored.
+ (spi_controller_update_key_grabs): Use GrabModeSync for pointer_mode
+ keyboard_mode so that XAllowEvents() can be called.
+
+ Fixes bug #93658.
+
+2002-10-08 Padraig O'Briain <padraig obriain sun com>
+
* cspi/spi-accessible.c: Correct names of roles returned by
AccessibleRole_getName(). Fixes bug #95055.
Index: registryd/deviceeventcontroller.c
===================================================================
RCS file: /cvs/gnome/at-spi/registryd/deviceeventcontroller.c,v
retrieving revision 1.46
diff -u -p -r1.46 deviceeventcontroller.c
--- registryd/deviceeventcontroller.c 16 Sep 2002 11:03:39 -0000 1.46
+++ registryd/deviceeventcontroller.c 8 Oct 2002 09:20:54 -0000
@@ -416,7 +416,7 @@ handle_keygrab (SpiDEController
{
grab_mask.key_val = AnyKey;
#ifdef SPI_DEBUG
- fprintf (stderr, "AnyKey grab!"); */
+ fprintf (stderr, "AnyKey grab!");
#endif
process_cb (controller, &grab_mask);
}
@@ -548,7 +548,7 @@ global_filter_fn (GdkXEvent *gdk_xevent,
XEvent *xevent = gdk_xevent;
SpiDEController *controller;
- if (xevent->type == KeyPress && xevent->type == KeyRelease)
+ if (xevent->type == KeyPress || xevent->type == KeyRelease)
{
controller = SPI_DEVICE_EVENT_CONTROLLER (data);
spi_device_event_controller_forward_key_event (controller, xevent);
@@ -594,7 +594,6 @@ spi_controller_register_with_devices (Sp
x_default_error_handler = XSetErrorHandler (_spi_controller_device_error_handler);
}
-#define SPI_KEYEVENT_DEBUG
static gboolean
spi_key_set_contains_key (Accessibility_KeySet *key_set,
const Accessibility_DeviceEvent *key_event)
@@ -973,15 +972,15 @@ spi_controller_update_key_grabs (SpiDECo
{
#ifdef SPI_DEBUG
- fprintf (stderr, "grab with mask %x\n", grab_mask->mod_mask);
+ fprintf (stderr, "grab %d with mask %x\n", grab_mask->key_val, grab_mask->mod_mask);
#endif
XGrabKey (spi_get_display (),
grab_mask->key_val,
grab_mask->mod_mask,
gdk_x11_get_default_root_xwindow (),
True,
- GrabModeAsync,
- GrabModeAsync);
+ GrabModeSync,
+ GrabModeSync);
XSync (spi_get_display (), False);
update_failed = spi_clear_error_state ();
if (update_failed) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]