+2002-06-12 Bill Haneman <bill.haneman@sun.com>
+
+ * test/Makefile.am:
+ Added target for new stress-test.
+
+ * test/stress-test.c:
+ New test, sends 1000 focus notifies in quick succession.
+
+ * test/key-listener-test.c:
+ Now we report whether a keylistener registration
+ request succeeded or failed.
+
+ * test/event-listener-test.c:
+ Uncommented some listeners which are now implemented.
+
+
2002-06-06 Bill Haneman <bill.haneman@sun.com>
* registryd/deviceeventcontroller.c:
"object:visible-data-changed");
SPI_registerGlobalEventListener (generic_listener,
"object:text-selection-changed");
+
SPI_registerGlobalEventListener (generic_listener,
"object:text-caret-moved");
SPI_registerGlobalEventListener (generic_listener,
"window:deactivate");
SPI_registerGlobalEventListener (generic_listener,
"window:close");
-#ifdef NOT_YET_IMPLEMENTED
SPI_registerGlobalEventListener (generic_listener,
"window:lower");
SPI_registerGlobalEventListener (generic_listener,
"window:shade");
SPI_registerGlobalEventListener (generic_listener,
"window:unshade");
+#ifdef NOT_YET_IMPLEMENTED
/* event below possibly should just be property change? */
SPI_registerGlobalEventListener (generic_listener,
"window:restyle");
void
report_event (const AccessibleEvent *event, void *user_data)
{
- fprintf (stderr, "%s\n", event->type);
+ char *s = Accessible_getName (event->source);
+ fprintf (stderr, "%s %s\n", event->type, s);
+ if (s) SPI_freeString (s);
}
void
{
char *tab_strings[1];
short keycodes[] = {65, 64, 23};
+ SPIBoolean retval = FALSE;
SPI_init ();
sync_keyset = SPI_createAccessibleKeySet (3, "def", NULL, NULL);
tab_strings[0] = "Tab";
tab_keyset = SPI_createAccessibleKeySet (1, NULL, NULL, tab_strings);
- SPI_registerAccessibleKeystrokeListener(command_key_listener,
- command_keyset,
+ retval = SPI_registerAccessibleKeystrokeListener(command_key_listener,
+ command_keyset,
SPI_KEYMASK_ALT | SPI_KEYMASK_CONTROL,
(unsigned long) ( SPI_KEY_PRESSED ),
SPI_KEYLISTENER_ALL_WINDOWS);
-
- SPI_registerAccessibleKeystrokeListener(ordinary_key_listener,
+ fprintf (stderr, "Command key registry: result %s\n", retval ? "succeeded" :
+ "failed");
+ retval = SPI_registerAccessibleKeystrokeListener(ordinary_key_listener,
async_keyset,
SPI_KEYMASK_UNMODIFIED,
(unsigned long) ( SPI_KEY_PRESSED | SPI_KEY_RELEASED ),
SPI_KEYLISTENER_NOSYNC);
- SPI_registerAccessibleKeystrokeListener(synchronous_key_listener,
+ retval = SPI_registerAccessibleKeystrokeListener(synchronous_key_listener,
sync_keyset,
SPI_KEYMASK_UNMODIFIED,
(unsigned long) ( SPI_KEY_PRESSED | SPI_KEY_RELEASED ),
SPI_KEYLISTENER_CANCONSUME);
- SPI_registerAccessibleKeystrokeListener(tab_key_listener,
+ retval = SPI_registerAccessibleKeystrokeListener(tab_key_listener,
tab_keyset,
SPI_KEYMASK_ALT,
(unsigned long) ( SPI_KEY_PRESSED | SPI_KEY_RELEASED ),
SPI_KEYLISTENER_ALL_WINDOWS);
+ fprintf (stderr, "tab listener registry: %s\n", retval ? "succeeded" : "failed");
- SPI_registerAccessibleKeystrokeListener(all_key_listener,
+ retval = SPI_registerAccessibleKeystrokeListener(all_key_listener,
SPI_KEYSET_ALL_KEYS,
- SPI_KEYMASK_UNMODIFIED,
+ SPI_KEYMASK_CONTROL,
(unsigned long) ( SPI_KEY_PRESSED | SPI_KEY_RELEASED ),
- SPI_KEYLISTENER_CANCONSUME);
+ SPI_KEYLISTENER_ALL_WINDOWS);
+
+ fprintf (stderr, "all key registry: %s\n", retval ? "succeeded" : "failed" );
+
+ SPI_registerAccessibleKeystrokeListener(all_key_listener,
+ SPI_KEYSET_ALL_KEYS,
+ SPI_KEYMASK_UNMODIFIED,
+ (unsigned long) ( SPI_KEY_PRESSED | SPI_KEY_RELEASED ),
+ SPI_KEYLISTENER_NOSYNC);
SPI_event_main ();