2 * AT-SPI - Assistive Technology Service Provider Interface
3 * (Gnome Accessibility Project; http://developer.gnome.org/projects/gap)
5 * Copyright 2001 Sun Microsystems Inc.
7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Library General Public
9 * License as published by the Free Software Foundation; either
10 * version 2 of the License, or (at your option) any later version.
12 * This library is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * Library General Public License for more details.
17 * You should have received a copy of the GNU Library General Public
18 * License along with this library; if not, write to the
19 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
20 * Boston, MA 02111-1307, USA.
23 #include <cspi/spi-private.h>
26 * createAccessibleEventListener:
27 * @callback : an #AccessibleEventListenerCB callback function, or NULL.
29 * Create a new #AccessibleEventListener with a specified (in-process) callback function.
31 * Returns: a pointer to a newly-created #AccessibleEventListener.
34 AccessibleEventListener *
35 createAccessibleEventListener (AccessibleEventListenerCB callback)
37 AccessibleEventListener *listener = spi_event_listener_new ();
40 spi_event_listener_add_callback (listener, callback);
46 * AccessibleEventListener_addCallback:
47 * @listener: the #AccessibleEventListener instance to modify.
48 * @callback: an #AccessibleEventListenerCB function pointer.
50 * Add an in-process callback function to an existing AccessibleEventListener.
51 * Note that the callback function must live in the same address
52 * space as the AccessibleEventListener implementation code, thus one should not
53 * use this function to attach callbacks to a 'remote' event listener
54 * (that is, one that was not created by a client call to
55 * createAccessibleEventListener ();
57 * Returns: #TRUE if successful, otherwise #FALSE.
61 AccessibleEventListener_addCallback (AccessibleEventListener *listener,
62 AccessibleEventListenerCB callback)
64 spi_event_listener_add_callback (listener, callback);
69 * AccessibleEventListener_removeCallback:
70 * @listener: the #AccessibleEventListener instance to modify.
71 * @callback: an #AccessibleEventListenerCB function pointer.
73 * Remove an in-process callback function from an existing AccessibleEventListener.
75 * Returns: #TRUE if successful, otherwise #FALSE.
79 AccessibleEventListener_removeCallback (AccessibleEventListener *listener,
80 AccessibleEventListenerCB callback)
82 /* spi_event_listener_remove_callback (listener, callback); */
87 * createAccessibleKeystrokeListener:
88 * @callback : an #AccessibleKeystrokeListenerCB callback function, or NULL.
90 * Create a new #AccessibleKeystrokeListener with a specified callback function.
92 * Returns: a pointer to a newly-created #AccessibleKeystrokeListener.
95 AccessibleKeystrokeListener *
96 createAccessibleKeystrokeListener (AccessibleKeystrokeListenerCB callback)
98 SpiKeystrokeListener *listener = spi_keystroke_listener_new ();
101 spi_keystroke_listener_add_callback (listener, callback);
103 return (AccessibleKeystrokeListener *)listener;
107 * AccessibleKeystrokeListener_addCallback:
108 * @listener: the #AccessibleKeystrokeListener instance to modify.
109 * @callback: an #AccessibleKeystrokeListenerCB function pointer.
111 * Add an in-process callback function to an existing #AccessibleKeystrokeListener.
113 * Returns: #TRUE if successful, otherwise #FALSE.
117 AccessibleKeystrokeListener_addCallback (AccessibleKeystrokeListener *listener,
118 AccessibleKeystrokeListenerCB callback)
120 spi_keystroke_listener_add_callback (listener, callback);
125 * AccessibleKeystrokeListener_removeCallback:
126 * @listener: the #AccessibleKeystrokeListener instance to modify.
127 * @callback: an #AccessibleKeystrokeListenerCB function pointer.
129 * Remove an in-process callback function from an existing #AccessibleKeystrokeListener.
131 * Returns: #TRUE if successful, otherwise #FALSE.
135 AccessibleKeystrokeListener_removeCallback (AccessibleKeystrokeListener *listener,
136 AccessibleKeystrokeListenerCB callback)
138 spi_keystroke_listener_remove_callback (listener, callback);